diff --git a/harbour/ChangeLog b/harbour/ChangeLog index f9dec1a5b5..b02f48780c 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,3 +1,8 @@ +19990816-15:30 GMT+1 Victor Szel + * source/rtl/errorapi.c + ! Fixed hb_errLaunch() so that it will handle error handler return + values correctly. NOTEs added about this. + 19990816-13:30 CET Eddie Runia * source/compiler/harbour.y EndProc error resolved. diff --git a/harbour/source/rtl/errorapi.c b/harbour/source/rtl/errorapi.c index 1a27aef27f..a5baee29be 100644 --- a/harbour/source/rtl/errorapi.c +++ b/harbour/source/rtl/errorapi.c @@ -59,17 +59,21 @@ WORD hb_errLaunch( PHB_ITEM pError ) exit( 1 ); /* TODO: quit correctly */ } + /* NOTE: This must be called before the hb_vm*() calls */ + uiFlags = hb_errGetFlags( pError ); + hb_vmPushSymbol( &symEval ); hb_vmPush( &errorBlock ); hb_vmPush( pError ); hb_vmDo( 1 ); + /* NOTE: Don't make any hb_vm*() calls here, since they may screw up */ + /* the stack.return value */ + /* TODO: Detect these properly */ bBreak = FALSE; nSequenceLevel = 0; - uiFlags = hb_errGetFlags( pError ); - if ( bBreak ) { if ( nSequenceLevel )