From 9d33b0d60a682bd57df13524bb902e360bfaa148 Mon Sep 17 00:00:00 2001 From: Przemyslaw Czerpak Date: Fri, 7 Oct 2011 22:31:07 +0000 Subject: [PATCH] 2011-10-08 00:30 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl) * harbour/contrib/rddbm/bmdbfx.c % simplified function used for resetting logical index position. --- harbour/ChangeLog | 4 ++++ harbour/contrib/rddbm/bmdbfx.c | 25 +++++-------------------- 2 files changed, 9 insertions(+), 20 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 5db14f1f82..bb35f91e83 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -16,6 +16,10 @@ The license applies to all entries newer than 2009-04-28. */ +2011-10-08 00:30 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl) + * harbour/contrib/rddbm/bmdbfx.c + % simplified function used for resetting logical index position. + 2011-10-06 08:02 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl) * harbour/contrib/xhb/xhb.hbx * harbour/contrib/xhb/xhbinkey.prg diff --git a/harbour/contrib/rddbm/bmdbfx.c b/harbour/contrib/rddbm/bmdbfx.c index 7e6928aab4..2b399a77c2 100644 --- a/harbour/contrib/rddbm/bmdbfx.c +++ b/harbour/contrib/rddbm/bmdbfx.c @@ -238,27 +238,12 @@ static const RDDFUNCS * hb_bmGetRdd( HB_USHORT uiRddId ) static void hb_bmResetFilterOpt( AREAP pArea ) { - PHB_ITEM itmCobExpr, abFilterText; - HB_BOOL fOptimized, fFilter; - void * lpvCargo; + DBORDERINFO OrderInfo; - itmCobExpr = pArea->dbfi.itmCobExpr; - abFilterText = pArea->dbfi.abFilterText; - fOptimized = pArea->dbfi.fOptimized; - fFilter = pArea->dbfi.fFilter; - lpvCargo = pArea->dbfi.lpvCargo; - - pArea->dbfi.itmCobExpr = NULL; - pArea->dbfi.abFilterText = NULL; - pArea->dbfi.lpvCargo = NULL; - - SELF_CLEARFILTER( pArea ); - - pArea->dbfi.itmCobExpr = itmCobExpr; - pArea->dbfi.abFilterText = abFilterText; - pArea->dbfi.fOptimized = fOptimized; - pArea->dbfi.fFilter = fFilter; - pArea->dbfi.lpvCargo = lpvCargo; + memset( &OrderInfo, 0, sizeof( OrderInfo ) ); + SELF_ORDINFO( pArea, DBOI_RESETPOS, &OrderInfo ); + if( OrderInfo.itmResult ) + hb_itemRelease( OrderInfo.itmResult ); } static HB_BOOL hb_bmCheckRecordFilter( AREAP pArea, HB_ULONG ulRecNo )