fix access to null pointer.
This commit is contained in:
parent
56a3fc5651
commit
2266bb9826
2
C/args.c
2
C/args.c
@ -68,6 +68,8 @@ Yap_ArgListToVector (Term listl, const param_t *def, int n)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
xarg *na = matchKey( NameOfFunctor( f ), a, n, def);
|
xarg *na = matchKey( NameOfFunctor( f ), a, n, def);
|
||||||
|
if (!na)
|
||||||
|
return NULL;
|
||||||
na->used = 1;
|
na->used = 1;
|
||||||
na->tvalue = ArgOfTerm(1, hd);
|
na->tvalue = ArgOfTerm(1, hd);
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user