[1434] in SIPB bug reports
[jfc@ATHENA.MIT.EDU: compile_et exit status]
daemon@ATHENA.MIT.EDU (Jonathan I. Kamens)
Mon Nov 12 10:00:56 1990
Date: Mon, 12 Nov 90 09:59:51 -0500
From: "Jonathan I. Kamens" <jik@pit-manager.MIT.EDU>
To: raeburn@ATHENA.MIT.EDU, bug-sipb@ATHENA.MIT.EDU
First, the bug:
----- Forwarded message
To: bugs@ATHENA.MIT.EDU
Subject: compile_et exit status
Date: Sun, 28 Oct 90 04:42:18 EST
From: John Carr <jfc@ATHENA.MIT.EDU>
% compile_et login_err.et
syntax error
Line number 25; last token was 'LOGIN_UTMP_NOENT'
%
The exit status was 0. It should have been something else. The error
was a missing "," on the line.
----- End of forwarded message
Now, the proposed fix:
*** /source/athena/athena.lib/et/compile_et.c Mon Feb 27 19:02:38 1989
--- compile_et.c Mon Nov 12 09:59:03 1990
***************
*** 130,135 ****
--- 130,136 ----
int len;
char const * const *cpp;
int got_language = 0;
+ extern int yynerrs;
/* argument parsing */
debug = 0;
***************
*** 248,253 ****
--- 249,262 ----
/* parse it */
yyparse();
fclose(yyin); /* bye bye input file */
+
+ if (yynerrs) {
+ fclose(cfile);
+ fclose(hfile);
+ unlink(c_file);
+ unlink(h_file);
+ return 1;
+ }
fputs (" 0\n};\n\n", cfile);
for (cpp = struct_def; *cpp; cpp++)
Any comments?
jik