UserCCode shouldn't be allowed to look up hidden atoms.
This commit is contained in:
parent
d690ffdb18
commit
98de122687
5
C/init.c
5
C/init.c
@ -409,7 +409,10 @@ Yap_InitCPred(char *Name, unsigned long int Arity, CPredicate code, UInt flags)
|
||||
Functor f = NULL;
|
||||
|
||||
while (atom == NIL) {
|
||||
atom = Yap_FullLookupAtom(Name);
|
||||
if (flags & UserCPredFlag)
|
||||
atom = Yap_LookupAtom(Name);
|
||||
else
|
||||
atom = Yap_FullLookupAtom(Name);
|
||||
if (atom == NIL && !Yap_growheap(FALSE, 0L, NULL)) {
|
||||
Yap_Error(OUT_OF_HEAP_ERROR,TermNil,"while initialising %s", Name);
|
||||
return;
|
||||
|
Reference in New Issue
Block a user