/*
* Copyright (c) 1980 Regents of the University of California.
- * All rights reserved. The Berkeley software License Agreement
+ * All rights reserved. The Berkeley Software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
-static char sccsid[] = "@(#)err.c 5.1 (Berkeley) %G%";
-#endif not lint
+static char *sccsid = "@(#)err.c 5.4 (Berkeley) %G%";
+#endif
#include "sh.h"
#include <sys/ioctl.h>
}
errspl = 0;
+ /*
+ * Go away if -e or we are a child shell
+ */
+ if (exiterr || child)
+ exit(1);
+
/*
* Reset the state of the input.
* This buffered seek to end of file will also
*/
btoeof();
- /*
- * Go away if -e or we are a child shell
- */
- if (exiterr || child)
- exit(1);
-
setq("status", onev, &shvhed);
if (tpgrp > 0)
(void) ioctl(FSHTTY, TIOCSPGRP, (char *)&tpgrp);
- reset(); /* Unwind */
+ longjmp(reslab, 0); /* Unwind */
}
/*