This source file includes following definitions.
- main
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 #include <config.h>
19
20
21 #include <string.h>
22
23 #include "signature.h"
24 SIGNATURE_CHECK (sigdescr_np, const char *, (int));
25
26 #include <signal.h>
27
28 #include "macros.h"
29
30 int
31 main (void)
32 {
33
34 ASSERT (strcmp (sigdescr_np (SIGABRT), "Aborted") == 0);
35 ASSERT (strcmp (sigdescr_np (SIGFPE), "Floating point exception") == 0
36 || strcmp (sigdescr_np (SIGFPE), "Arithmetic exception") == 0);
37 ASSERT (strcmp (sigdescr_np (SIGILL), "Illegal instruction") == 0);
38 ASSERT (strcmp (sigdescr_np (SIGINT), "Interrupt") == 0);
39 ASSERT (strcmp (sigdescr_np (SIGSEGV), "Segmentation fault") == 0);
40 ASSERT (strcmp (sigdescr_np (SIGTERM), "Terminated") == 0);
41
42
43
44 #ifdef SIGALRM
45 ASSERT (strcmp (sigdescr_np (SIGALRM), "Alarm clock") == 0);
46 #endif
47 #ifdef SIGBUS
48 ASSERT (strcmp (sigdescr_np (SIGBUS), "Bus error") == 0);
49 #endif
50 #ifdef SIGCHLD
51 ASSERT (strcmp (sigdescr_np (SIGCHLD), "Child exited") == 0
52 || strcmp (sigdescr_np (SIGCHLD), "Child stopped or exited") == 0);
53 #endif
54 #ifdef SIGCONT
55 ASSERT (strcmp (sigdescr_np (SIGCONT), "Continued") == 0);
56 #endif
57 #ifdef SIGHUP
58 ASSERT (strcmp (sigdescr_np (SIGHUP), "Hangup") == 0);
59 #endif
60 #ifdef SIGKILL
61 ASSERT (strcmp (sigdescr_np (SIGKILL), "Killed") == 0);
62 #endif
63 #ifdef SIGPIPE
64 ASSERT (strcmp (sigdescr_np (SIGPIPE), "Broken pipe") == 0);
65 #endif
66 #ifdef SIGQUIT
67 ASSERT (strcmp (sigdescr_np (SIGQUIT), "Quit") == 0);
68 #endif
69 #ifdef SIGSTOP
70 ASSERT (strcmp (sigdescr_np (SIGSTOP), "Stopped (signal)") == 0);
71 #endif
72 #ifdef SIGTSTP
73 ASSERT (strcmp (sigdescr_np (SIGTSTP), "Stopped") == 0);
74 #endif
75 #ifdef SIGTTIN
76 ASSERT (strcmp (sigdescr_np (SIGTTIN), "Stopped (tty input)") == 0);
77 #endif
78 #ifdef SIGTTOU
79 ASSERT (strcmp (sigdescr_np (SIGTTOU), "Stopped (tty output)") == 0);
80 #endif
81 #ifdef SIGUSR1
82 ASSERT (strcmp (sigdescr_np (SIGUSR1), "User defined signal 1") == 0);
83 #endif
84 #ifdef SIGUSR2
85 ASSERT (strcmp (sigdescr_np (SIGUSR2), "User defined signal 2") == 0);
86 #endif
87 #ifdef SIGPOLL
88 ASSERT (strcmp (sigdescr_np (SIGPOLL), "I/O possible") == 0);
89 #endif
90 #ifdef SIGPROF
91 ASSERT (strcmp (sigdescr_np (SIGPROF), "Profiling timer expired") == 0);
92 #endif
93 #ifdef SIGSYS
94 ASSERT (strcmp (sigdescr_np (SIGSYS), "Bad system call") == 0);
95 #endif
96 #ifdef SIGTRAP
97 ASSERT (strcmp (sigdescr_np (SIGTRAP), "Trace/breakpoint trap") == 0);
98 #endif
99 #ifdef SIGURG
100 ASSERT (strcmp (sigdescr_np (SIGURG), "Urgent I/O condition") == 0);
101 #endif
102 #ifdef SIGVTALRM
103 ASSERT (strcmp (sigdescr_np (SIGVTALRM), "Virtual timer expired") == 0);
104 #endif
105 #ifdef SIGXCPU
106 ASSERT (strcmp (sigdescr_np (SIGXCPU), "CPU time limit exceeded") == 0);
107 #endif
108 #ifdef SIGXFSZ
109 ASSERT (strcmp (sigdescr_np (SIGXFSZ), "File size limit exceeded") == 0);
110 #endif
111
112
113
114 #ifdef SIGBREAK
115 ASSERT (strcmp (sigdescr_np (SIGBREAK), "Ctrl-Break") == 0);
116 #endif
117
118 #ifdef SIGCKPT
119 ASSERT (strcmp (sigdescr_np (SIGCKPT), "Checkpoint") == 0);
120 #endif
121
122 #ifdef SIGCPUFAIL
123 ASSERT (strcmp (sigdescr_np (SIGCPUFAIL), "CPU going down") == 0);
124 #endif
125
126 #ifdef SIGDANGER
127 ASSERT (strcmp (sigdescr_np (SIGDANGER), "Swap space nearly exhausted") == 0);
128 #endif
129
130 #ifdef SIGEMT
131 ASSERT (strcmp (sigdescr_np (SIGEMT), "Instruction emulation needed") == 0);
132 #endif
133
134 #if defined SIGINFO && SIGINFO != SIGPWR
135 ASSERT (strcmp (sigdescr_np (SIGINFO), "Information request") == 0);
136 #endif
137
138 #ifdef SIGKAP
139 ASSERT (strcmp (sigdescr_np (SIGKAP), "Keep Alive Poll") == 0);
140 #endif
141
142 #ifdef SIGKILLTHR
143 ASSERT (strcmp (sigdescr_np (SIGKILLTHR), "Kill thread") == 0);
144 #endif
145
146 #ifdef SIGKMEM
147 ASSERT (strcmp (sigdescr_np (SIGKMEM), "Kernel memory request") == 0);
148 #endif
149
150 #ifdef SIGKMESS
151 ASSERT (strcmp (sigdescr_np (SIGKMESS), "Kernel message") == 0);
152 #endif
153
154 #ifdef SIGKSIG
155 ASSERT (strcmp (sigdescr_np (SIGKSIG), "Kernel signal") == 0);
156 #endif
157
158 #ifdef SIGKSIGSM
159 ASSERT (strcmp (sigdescr_np (SIGKSIGSM), "Kernel signal for signal manager") == 0);
160 #endif
161
162 #ifdef SIGLIBRT
163 ASSERT (strcmp (sigdescr_np (SIGLIBRT), "Real-time library interrupt") == 0);
164 #endif
165
166 #ifdef SIGMIGRATE
167 ASSERT (strcmp (sigdescr_np (SIGMIGRATE), "Process migration") == 0);
168 #endif
169
170 #ifdef SIGMSG
171 ASSERT (strcmp (sigdescr_np (SIGMSG), "Message in the ring") == 0);
172 #endif
173
174 #ifdef SIGPRE
175 ASSERT (strcmp (sigdescr_np (SIGPRE), "Programmed exception") == 0);
176 #endif
177
178 #ifdef SIGPTINTR
179 ASSERT (strcmp (sigdescr_np (SIGPTINTR), "Pthread interrupt") == 0);
180 #endif
181
182 #ifdef SIGPTRESCHED
183 ASSERT (strcmp (sigdescr_np (SIGPTRESCHED), "Pthread rescheduling") == 0);
184 #endif
185
186 #ifdef SIGPWR
187 ASSERT (strcmp (sigdescr_np (SIGPWR), "Power failure") == 0);
188 #endif
189
190 #ifdef SIGRECONFIG
191 ASSERT (strcmp (sigdescr_np (SIGRECONFIG), "Dynamic logical partitioning changed") == 0);
192 #endif
193
194 #ifdef SIGRECOVERY
195 ASSERT (strcmp (sigdescr_np (SIGRECOVERY), "Kernel recovery") == 0);
196 #endif
197
198 #ifdef SIGRESTART
199 ASSERT (strcmp (sigdescr_np (SIGRESTART), "Checkpoint restart") == 0);
200 #endif
201
202 #ifdef SIGRETRACT
203 ASSERT (strcmp (sigdescr_np (SIGRETRACT), "Retracting Keep Alive Poll") == 0);
204 #endif
205
206 #ifdef SIGSAK
207 ASSERT (strcmp (sigdescr_np (SIGSAK), "Secure Attention Key") == 0);
208 #endif
209
210 #ifdef SIGSNDELAY
211 ASSERT (strcmp (sigdescr_np (SIGSNDELAY), "Done sending message") == 0);
212 #endif
213
214 #ifdef SIGSOUND
215 ASSERT (strcmp (sigdescr_np (SIGSOUND), "Sound configuration changed") == 0);
216 #endif
217
218 #ifdef SIGSTKFLT
219 ASSERT (strcmp (sigdescr_np (SIGSTKFLT), "Stack fault") == 0);
220 #endif
221
222 #ifdef SIGSYSERROR
223 ASSERT (strcmp (sigdescr_np (SIGSYSERROR), "Kernel error") == 0);
224 #endif
225
226 #ifdef SIGTALRM
227 ASSERT (strcmp (sigdescr_np (SIGTALRM), "Thread alarm clock") == 0);
228 #endif
229
230 #ifdef SIGTHR
231 ASSERT (strcmp (sigdescr_np (SIGTHR), "Thread library interrupt") == 0);
232 #endif
233
234 #ifdef SIGUME
235 ASSERT (strcmp (sigdescr_np (SIGUME), "Uncorrectable memory error") == 0);
236 #endif
237
238 #ifdef SIGVIRT
239 ASSERT (strcmp (sigdescr_np (SIGVIRT), "Virtual time alarm clock") == 0);
240 #endif
241
242 #ifdef SIGWAITING
243 ASSERT (strcmp (sigdescr_np (SIGWAITING), "Thread waiting") == 0);
244 #endif
245
246 #ifdef SIGWINCH
247 ASSERT (strcmp (sigdescr_np (SIGWINCH), "Window changed") == 0
248 || strcmp (sigdescr_np (SIGWINCH), "Window size changed") == 0);
249 #endif
250
251 ASSERT (sigdescr_np (-714) == NULL);
252
253 return 0;
254 }