don't trust Error_TYPE unless ErrorMessage is set

fix ^cstats fix


git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@401 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
vsc
2002-03-07 05:47:24 +00:00
parent 7c6b48a20d
commit 8b97aac875
3 changed files with 8 additions and 6 deletions

View File

@@ -2718,7 +2718,7 @@ cclause(Term inp_clause, int NOfArgs, int mod)
/* may botch while doing a different module */
/* first, initialise CompilerBotch to handle all cases of interruptions */
ErrorMessage = NIL;
ErrorMessage = NULL;
if ((botch_why = setjmp(CompilerBotch)) == 3) {
/* out of local stack, just duplicate the stack */
restore_machine_regs();
@@ -2759,7 +2759,7 @@ cclause(Term inp_clause, int NOfArgs, int mod)
return(0);
}
restart_compilation:
if (ErrorMessage != NIL) {
if (ErrorMessage != NULL) {
reset_vars();
return (0);
}