From a5ad762cb09fa97f0c46c3bf8ee0778da6567bf3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Przemys=C5=82aw=20Czerpak?= Date: Thu, 7 Mar 2024 13:41:15 +0100 Subject: [PATCH] 2024-03-07 13:41 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl) * contrib/gtqtc/gtqtc.hbp ! do not detect QT5 when HB_BUILD_3RDEXT=no is set * debian/rules * removed LD_LIBRARY_PATH setting * src/rdd/dbcmd.c * src/rdd/wacore.c ! moved code checking WA number from DbSelectArea() PRG function to hb_rddSelectWorkAreaNumber() C function. It fixes few things like: DbSelectArea( 0 ) and also: ? ( 0 )->( select() ) --- ChangeLog.txt | 16 ++++++++++++++++ contrib/gtqtc/gtqtc.hbp | 1 + debian/rules | 6 ------ src/rdd/dbcmd.c | 14 +------------- src/rdd/wacore.c | 7 ++++--- 5 files changed, 22 insertions(+), 22 deletions(-) diff --git a/ChangeLog.txt b/ChangeLog.txt index 3b0e468c96..e1736f5706 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -7,6 +7,22 @@ Entries may not always be in chronological/commit order. See license at the end of file. */ +2024-03-07 13:41 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl) + * contrib/gtqtc/gtqtc.hbp + ! do not detect QT5 when HB_BUILD_3RDEXT=no is set + + * debian/rules + * removed LD_LIBRARY_PATH setting + + * src/rdd/dbcmd.c + * src/rdd/wacore.c + ! moved code checking WA number from DbSelectArea() PRG function + to hb_rddSelectWorkAreaNumber() C function. It fixes few things + like: + DbSelectArea( 0 ) + and also: + ? ( 0 )->( select() ) + 2024-02-16 18:23 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl) * contrib/hbexpat/3rd/expat/expat.diff * contrib/hbexpat/3rd/expat/loadlibr.c diff --git a/contrib/gtqtc/gtqtc.hbp b/contrib/gtqtc/gtqtc.hbp index b88c887963..aa20c3e621 100644 --- a/contrib/gtqtc/gtqtc.hbp +++ b/contrib/gtqtc/gtqtc.hbp @@ -24,6 +24,7 @@ -deppkgname=qt5:qt5 -depkeyhead=qt5:QtCore/QJsonObject -depcontrol=qt5:${HB_WITH_QT} +{HB_BUILD_3RDEXT='no'}-depoptional=qt5:no -depoptional=qt5:yes -depincpath=qt5:/usr/include/x86_64-linux-gnu/qt5{linux} -depincpath=qt5:/usr/local/opt/qt5/include{darwin} diff --git a/debian/rules b/debian/rules index 38adae8514..f490fdea15 100755 --- a/debian/rules +++ b/debian/rules @@ -20,12 +20,6 @@ export HB_INSTALL_MAN := $(HB_INSTALL_PKG_ROOT)/usr/share/man export HB_INSTALL_ETC := $(HB_INSTALL_PKG_ROOT)/etc/harbour export HB_INSTALL_CONTRIB := $(HB_INSTALL_PKG_ROOT)/usr/share/harbour/contrib -ifeq ($(LD_LIBRARY_PATH),) - export LD_LIBRARY_PATH := $(HB_INSTALL_DYN) -else - export LD_LIBRARY_PATH := $(LD_LIBRARY_PATH):$(HB_INSTALL_DYN) -endif - export HB_SYSLOC := yes export HB_BUILD_PKG := no export HB_BUILD_SHARED := yes diff --git a/src/rdd/dbcmd.c b/src/rdd/dbcmd.c index 208499653b..282b010126 100644 --- a/src/rdd/dbcmd.c +++ b/src/rdd/dbcmd.c @@ -747,19 +747,7 @@ HB_FUNC( DBSELECTAREA ) iNewArea = ( int ) hb_dynsymAreaHandle( pSymAlias->pDynSym ); } } - /* - * NOTE: iNewArea >= HB_RDD_MAX_AREA_NUM used intentionally - * In Clipper area 65535 is reserved for "M" alias [druzus] - */ - if( iNewArea < 1 || iNewArea >= HB_RDD_MAX_AREA_NUM ) - { - if( hb_rddSelectFirstAvailable() != HB_SUCCESS ) - hb_rddSelectWorkAreaNumber( 0 ); - } - else - { - hb_rddSelectWorkAreaNumber( iNewArea ); - } + hb_rddSelectWorkAreaNumber( iNewArea ); } } diff --git a/src/rdd/wacore.c b/src/rdd/wacore.c index 7f8991dc02..78fbf2c6de 100644 --- a/src/rdd/wacore.c +++ b/src/rdd/wacore.c @@ -500,10 +500,11 @@ HB_ERRCODE hb_rddSelectWorkAreaNumber( int iArea ) HB_TRACE( HB_TR_DEBUG, ( "hb_rddSelectWorkAreaNumber(%d)", iArea ) ); pRddInfo = hb_stackRDD(); - if( iArea < 1 || iArea > HB_RDD_MAX_AREA_NUM ) - HB_SET_WA( 0 ); - else + + if( iArea >= 1 && iArea <= HB_RDD_MAX_AREA_NUM ) HB_SET_WA( ( HB_AREANO ) iArea ); + else if( hb_rddSelectFirstAvailable() != HB_SUCCESS ) + HB_SET_WA( 0 ); return ( pRddInfo->pCurrArea == NULL ) ? HB_FAILURE : HB_SUCCESS; }