don't blow up with bad modules
This commit is contained in:
parent
d0658b7b53
commit
66709db4bb
2
C/exec.c
2
C/exec.c
|
@ -1091,8 +1091,8 @@ static Int do_term_expansion(USES_REGS1) {
|
|||
Term mg_args[2];
|
||||
Term g = Yap_YapStripModule(ARG1, &cmod);
|
||||
yhandle_t h1 = Yap_InitSlot(g), h2 = Yap_InitSlot(ARG2);
|
||||
|
||||
/* user:term_expansion(A,B) */
|
||||
|
||||
ARG1 = g;
|
||||
if ((pe = RepPredProp(Yap_GetPredPropByFunc(FunctorTermExpansion, USER_MODULE))) &&
|
||||
pe->OpcodeOfPred != FAIL_OPCODE && pe->OpcodeOfPred != UNDEF_OPCODE &&
|
||||
|
|
Reference in New Issue