fix overflow handling in meta-calls.
This commit is contained in:
parent
f09e115106
commit
f9a7741781
11
C/absmi.c
11
C/absmi.c
@ -13695,6 +13695,7 @@ Yap_absmi(int inp)
|
|||||||
/* fetch the module from PREG */
|
/* fetch the module from PREG */
|
||||||
mod = PREG->y_u.Osbmp.mod;
|
mod = PREG->y_u.Osbmp.mod;
|
||||||
start_execute:
|
start_execute:
|
||||||
|
/* place to cut to */
|
||||||
b_ptr = B;
|
b_ptr = B;
|
||||||
/* we have mod, and ARG1 has the goal, let us roll */
|
/* we have mod, and ARG1 has the goal, let us roll */
|
||||||
/* Try to preserve the environment */
|
/* Try to preserve the environment */
|
||||||
@ -13837,7 +13838,7 @@ Yap_absmi(int inp)
|
|||||||
goto execute_metacall;
|
goto execute_metacall;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* execute, byt test first for interrupts */
|
/* execute, but test first for interrupts */
|
||||||
execute_end:
|
execute_end:
|
||||||
/* code copied from call */
|
/* code copied from call */
|
||||||
#ifndef NO_CHECKING
|
#ifndef NO_CHECKING
|
||||||
@ -13891,13 +13892,13 @@ Yap_absmi(int inp)
|
|||||||
NoStackPExecute:
|
NoStackPExecute:
|
||||||
WRITEBACK_Y_AS_ENV();
|
WRITEBACK_Y_AS_ENV();
|
||||||
#ifdef SHADOW_S
|
#ifdef SHADOW_S
|
||||||
Yap_REGS.S_ = SREG;
|
Yap_REGS.S_ = SREG;
|
||||||
#endif
|
#endif
|
||||||
saveregs();
|
saveregs_and_ycache();
|
||||||
d0 = interrupt_pexecute( pen PASS_REGS );
|
d0 = interrupt_pexecute( pen PASS_REGS );
|
||||||
setregs();
|
setregs_and_ycache();
|
||||||
#ifdef SHADOW_S
|
#ifdef SHADOW_S
|
||||||
SREG = Yap_REGS.S_;
|
SREG = Yap_REGS.S_;
|
||||||
#endif
|
#endif
|
||||||
if (!d0) FAIL();
|
if (!d0) FAIL();
|
||||||
if (d0 == 2) goto execute_stack_checked;
|
if (d0 == 2) goto execute_stack_checked;
|
||||||
|
Reference in New Issue
Block a user