Last change
on this file was 1392, checked in by bird, 21 years ago |
This commit was generated by cvs2svn to compensate for changes in r1391,
which included commits to RCS files with non-trunk default branches.
|
-
Property cvs2svn:cvs-rev
set to
1.1.1.2
-
Property svn:eol-style
set to
native
-
Property svn:executable
set to
*
|
File size:
541 bytes
|
Line | |
---|
1 | #include <stdio.h>
|
---|
2 | #include <signal.h>
|
---|
3 |
|
---|
4 | #ifndef SIGIOT
|
---|
5 | #ifdef SIGABRT
|
---|
6 | #define SIGIOT SIGABRT
|
---|
7 | #endif
|
---|
8 | #endif
|
---|
9 |
|
---|
10 | #include <stdlib.h>
|
---|
11 | extern void f_exit (void);
|
---|
12 |
|
---|
13 | void
|
---|
14 | sig_die (register char *s, int kill)
|
---|
15 | {
|
---|
16 | /* print error message, then clear buffers */
|
---|
17 | fprintf (stderr, "%s\n", s);
|
---|
18 |
|
---|
19 | if (kill)
|
---|
20 | {
|
---|
21 | fflush (stderr);
|
---|
22 | f_exit ();
|
---|
23 | fflush (stderr);
|
---|
24 | /* now get a core */
|
---|
25 | #ifdef SIGIOT
|
---|
26 | signal (SIGIOT, SIG_DFL);
|
---|
27 | #endif
|
---|
28 | abort ();
|
---|
29 | }
|
---|
30 | else
|
---|
31 | {
|
---|
32 | #ifdef NO_ONEXIT
|
---|
33 | f_exit ();
|
---|
34 | #endif
|
---|
35 | exit (1);
|
---|
36 | }
|
---|
37 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.