some fixes on hb_setFreeSetPath()

This commit is contained in:
Antonio Linares
2002-03-04 21:31:40 +00:00
parent 9580374663
commit 6b18c226f4

View File

@@ -80,20 +80,23 @@ static void hb_setFreeSetPath( void )
/* Free all set paths */
HB_PATHNAMES * curPath = sp_set_path;
HB_PATHNAMES * nextPath;
while( curPath )
{
nextPath = curPath->pNext;
hb_xfree( curPath );
curPath = nextPath;
}
if( sp_set_path )
{
/* Only the first path holds an allocated string.
All of the other paths in the list are part of
that first string. */
hb_xfree( sp_set_path->szPath );
sp_set_path = NULL;
}
while( curPath )
{
nextPath = curPath->pNext;
hb_xfree( curPath );
curPath = nextPath;
}
sp_set_path = NULL;
}
static BOOL set_logical( PHB_ITEM pItem )