OLD | NEW |
1 // Copyright 2009 The Go Authors. All rights reserved. | 1 // Copyright 2009 The Go Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style | 2 // Use of this source code is governed by a BSD-style |
3 // license that can be found in the LICENSE file. | 3 // license that can be found in the LICENSE file. |
4 | 4 |
5 #define C SigCatch | 5 #define C SigCatch |
6 #define I SigIgnore | 6 #define I SigIgnore |
7 #define R SigRestart | 7 #define R SigRestart |
8 #define Q SigQueue | 8 #define Q SigQueue |
| 9 #define P SigPanic |
9 | 10 |
10 static SigTab sigtab[] = { | 11 SigTab sigtab[] = { |
11 /* 0 */ 0, "SIGNONE: no trap", | 12 /* 0 */ 0, "SIGNONE: no trap", |
12 /* 1 */ Q+R, "SIGHUP: terminal line hangup", | 13 /* 1 */ Q+R, "SIGHUP: terminal line hangup", |
13 /* 2 */ Q+R, "SIGINT: interrupt", | 14 /* 2 */ Q+R, "SIGINT: interrupt", |
14 /* 3 */ C, "SIGQUIT: quit", | 15 /* 3 */ C, "SIGQUIT: quit", |
15 /* 4 */ C, "SIGILL: illegal instruction", | 16 /* 4 */ C, "SIGILL: illegal instruction", |
16 /* 5 */ C, "SIGTRAP: trace trap", | 17 /* 5 */ C, "SIGTRAP: trace trap", |
17 /* 6 */ C, "SIGABRT: abort", | 18 /* 6 */ C, "SIGABRT: abort", |
18 /* 7 */ C, "SIGEMT: EMT instruction", | 19 /* 7 */ C, "SIGEMT: EMT instruction", |
19 » /* 8 */»» C, "SIGFPE: floating-point exception", | 20 » /* 8 */»» C+P, "SIGFPE: floating-point exception", |
20 /* 9 */ 0, "SIGKILL: kill", | 21 /* 9 */ 0, "SIGKILL: kill", |
21 » /* 10 */» C, "SIGBUS: bus error", | 22 » /* 10 */» C+P, "SIGBUS: bus error", |
22 » /* 11 */» C, "SIGSEGV: segmentation violation", | 23 » /* 11 */» C+P, "SIGSEGV: segmentation violation", |
23 /* 12 */ C, "SIGSYS: bad system call", | 24 /* 12 */ C, "SIGSYS: bad system call", |
24 /* 13 */ I, "SIGPIPE: write to broken pipe", | 25 /* 13 */ I, "SIGPIPE: write to broken pipe", |
25 /* 14 */ Q+I+R, "SIGALRM: alarm clock", | 26 /* 14 */ Q+I+R, "SIGALRM: alarm clock", |
26 /* 15 */ Q+R, "SIGTERM: termination", | 27 /* 15 */ Q+R, "SIGTERM: termination", |
27 /* 16 */ Q+I+R, "SIGURG: urgent condition on socket", | 28 /* 16 */ Q+I+R, "SIGURG: urgent condition on socket", |
28 /* 17 */ 0, "SIGSTOP: stop, unblockable", | 29 /* 17 */ 0, "SIGSTOP: stop, unblockable", |
29 /* 18 */ Q+I+R, "SIGTSTP: stop from tty", | 30 /* 18 */ Q+I+R, "SIGTSTP: stop from tty", |
30 /* 19 */ 0, "SIGCONT: continue", | 31 /* 19 */ 0, "SIGCONT: continue", |
31 /* 20 */ Q+I+R, "SIGCHLD: child status has changed", | 32 /* 20 */ Q+I+R, "SIGCHLD: child status has changed", |
32 /* 21 */ Q+I+R, "SIGTTIN: background read from tty", | 33 /* 21 */ Q+I+R, "SIGTTIN: background read from tty", |
33 /* 22 */ Q+I+R, "SIGTTOU: background write to tty", | 34 /* 22 */ Q+I+R, "SIGTTOU: background write to tty", |
34 /* 23 */ Q+I+R, "SIGIO: i/o now possible", | 35 /* 23 */ Q+I+R, "SIGIO: i/o now possible", |
35 /* 24 */ Q+I+R, "SIGXCPU: cpu limit exceeded", | 36 /* 24 */ Q+I+R, "SIGXCPU: cpu limit exceeded", |
36 /* 25 */ Q+I+R, "SIGXFSZ: file size limit exceeded", | 37 /* 25 */ Q+I+R, "SIGXFSZ: file size limit exceeded", |
37 /* 26 */ Q+I+R, "SIGVTALRM: virtual alarm clock", | 38 /* 26 */ Q+I+R, "SIGVTALRM: virtual alarm clock", |
38 /* 27 */ Q+I+R, "SIGPROF: profiling alarm clock", | 39 /* 27 */ Q+I+R, "SIGPROF: profiling alarm clock", |
39 /* 28 */ Q+I+R, "SIGWINCH: window size change", | 40 /* 28 */ Q+I+R, "SIGWINCH: window size change", |
40 /* 29 */ Q+I+R, "SIGINFO: information request", | 41 /* 29 */ Q+I+R, "SIGINFO: information request", |
41 /* 30 */ Q+I+R, "SIGUSR1: user-defined signal 1", | 42 /* 30 */ Q+I+R, "SIGUSR1: user-defined signal 1", |
42 /* 31 */ Q+I+R, "SIGUSR2: user-defined signal 2", | 43 /* 31 */ Q+I+R, "SIGUSR2: user-defined signal 2", |
43 /* 32 */ Q+I+R, "SIGTHR: reserved", | 44 /* 32 */ Q+I+R, "SIGTHR: reserved", |
44 }; | 45 }; |
45 #undef C | 46 #undef C |
46 #undef I | 47 #undef I |
47 #undef R | 48 #undef R |
48 #undef Q | 49 #undef Q |
| 50 #undef P |
49 | 51 |
50 #define NSIG 33 | 52 #define NSIG 33 |
OLD | NEW |