From 4523578656f76c334ed247c9629715f87db7ea8b Mon Sep 17 00:00:00 2001 From: Antonio Linares Date: Mon, 18 Mar 2002 12:52:17 +0000 Subject: [PATCH] bug fixed on __MVSAVE() --- harbour/source/vm/memvars.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/harbour/source/vm/memvars.c b/harbour/source/vm/memvars.c index 6cc26d3801..1fc3b37344 100644 --- a/harbour/source/vm/memvars.c +++ b/harbour/source/vm/memvars.c @@ -1306,14 +1306,11 @@ HB_FUNC( __MVSAVE ) /* Walk through all visible memory variables */ - ULONG ulBase = s_privateStackCnt; + ULONG ulBase = 0; - while( ulBase > s_privateStackBase ) + while( ulBase < s_privateStackCnt ) { - PHB_DYNS pDynVar; - - --ulBase; - pDynVar = s_privateStack[ ulBase ]; + PHB_DYNS pDynVar = s_privateStack[ ulBase ]; /* NOTE: Harbour name lengths are not limited, but the .MEM file structure is not flexible enough to allow for it. @@ -1394,6 +1391,7 @@ HB_FUNC( __MVSAVE ) } } } + ulBase++; } buffer[ 0 ] = '\x1A'; @@ -1591,4 +1589,4 @@ PHB_ITEM hb_memvarGetValueByHandle( HB_HANDLE hMemvar ) return &s_globalTable[ hMemvar ].item; else return NULL; -} +} \ No newline at end of file