Replace all exit() with SWIG_exit()

For consistent cleanup on error
This commit is contained in:
William S Fulton 2019-07-29 19:35:54 +01:00
commit 2cf075558c
11 changed files with 24 additions and 24 deletions

View file

@ -833,7 +833,7 @@ static int look(Scanner *s) {
return SWIG_TOKEN_MODEQUAL;
} else if (c == '}') {
Swig_error(cparse_file, cparse_line, "Syntax error. Extraneous '%%}'\n");
exit(1);
SWIG_exit(EXIT_FAILURE);
} else {
retract(s, 1);
return SWIG_TOKEN_PERCENT;