repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
deque.tcc, [...]: Re-indent contents of namespace std, re-wrap comment lines as neces...
[official-gcc.git]
/
libf2c
/
libF77
/
sig_die.c
blob
622462e248baa68968c2736350b5a48d99773e34
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
}