macro and text revision (-mdoc version 3)
[unix-history] / usr / src / lib / libc / gen / setjmperr.c
... / ...
CommitLineData
1/*
2 * Copyright (c) 1980 Regents of the University of California.
3 * All rights reserved.
4 *
5 * %sccs.include.redist.c%
6 */
7
8#if defined(LIBC_SCCS) && !defined(lint)
9static char sccsid[] = "@(#)setjmperr.c 5.8 (Berkeley) %G%";
10#endif /* LIBC_SCCS and not lint */
11
12/*
13 * This routine is called from longjmp() when an error occurs.
14 * Programs that wish to exit gracefully from this error may
15 * write their own versions.
16 * If this routine returns, the program is aborted.
17 */
18
19#include <setjmp.h>
20#include <unistd.h>
21
22void
23longjmperror()
24{
25#define ERRMSG "longjmp botch.\n"
26 (void)write(STDERR_FILENO, ERRMSG, sizeof(ERRMSG) - 1);
27}