xref: /csrg-svn/lib/libc/gen/setjmperr.c (revision 42626)
125783Smckusick /*
225783Smckusick  * Copyright (c) 1980 Regents of the University of California.
334437Sbostic  * All rights reserved.
434437Sbostic  *
5*42626Sbostic  * %sccs.include.redist.c%
625783Smckusick  */
725783Smckusick 
826682Sdonn #if defined(LIBC_SCCS) && !defined(lint)
9*42626Sbostic static char sccsid[] = "@(#)setjmperr.c	5.6 (Berkeley) 06/01/90";
1034437Sbostic #endif /* LIBC_SCCS and not lint */
1125783Smckusick 
1225783Smckusick /*
1325783Smckusick  * This routine is called from longjmp() when an error occurs.
1425783Smckusick  * Programs that wish to exit gracefully from this error may
1525783Smckusick  * write their own versions.
1625783Smckusick  * If this routine returns, the program is aborted.
1725783Smckusick  */
1834437Sbostic 
1942392Sbostic #include <stdio.h>
2042392Sbostic 
2125783Smckusick longjmperror()
2225783Smckusick {
2334437Sbostic #define	ERRMSG	"longjmp botch\n"
2442392Sbostic 	write(fileno(stderr), ERRMSG, sizeof(ERRMSG) - 1);
2525783Smckusick }
26