If function is not found, bail out if strict_errorhandling is set.

This commit is contained in:
Holger Vogt 2022-01-15 14:09:50 +01:00
parent 632f8c033d
commit 46696a6aaa
1 changed files with 5 additions and 0 deletions

View File

@ -15,6 +15,8 @@ Author: 1987 Wayne A. Christopher, U. C. Berkeley CAD Group
#include "inpptree-parser.h"
#include "inpptree-parser-y.h"
extern bool ft_stricterror;
#ifdef OLD_BISON
int PTparse(char **line, INPparseNode **p, CKTcircuit *ckt);
#endif
@ -1109,6 +1111,9 @@ INPparseNode *PT_mkfnode(const char *fname, INPparseNode * arg)
if (i == NUM_FUNCS) {
fprintf(stderr, "Error: no such function '%s'\n", buf);
if (ft_stricterror)
controlled_exit(EXIT_BAD);
return mkfirst(NULL, arg);
}