OLD | NEW |
1 /* Compiler options: | 1 /* Compiler options: |
2 #notarget: cris*-*-elf | 2 #notarget: cris*-*-elf |
3 #cc: additional_flags=-pthread | 3 #cc: additional_flags=-pthread |
4 #xerror: | 4 #xerror: |
5 #output: Unimplemented rt_sigprocmask syscall (0x3, 0x0, 0x3dff*\n | 5 #output: Unimplemented rt_sigprocmask syscall (0x3, 0x0, 0x3dff*\n |
6 #output: program stopped with signal 4.\n | 6 #output: program stopped with signal 4 (*).\n |
7 | 7 |
8 Testing a signal handler corner case. */ | 8 Testing a signal handler corner case. */ |
9 | 9 |
10 #include <stddef.h> | 10 #include <stddef.h> |
11 #include <stdlib.h> | 11 #include <stdlib.h> |
12 #include <stdio.h> | 12 #include <stdio.h> |
13 #include <unistd.h> | 13 #include <unistd.h> |
14 #include <signal.h> | 14 #include <signal.h> |
15 #include <pthread.h> | 15 #include <pthread.h> |
16 #include <errno.h> | 16 #include <errno.h> |
(...skipping 25 matching lines...) Expand all Loading... |
42 retcode | 42 retcode |
43 = pthread_sigmask (SIG_BLOCK + SIG_UNBLOCK + SIG_SETMASK, NULL, &sigs); | 43 = pthread_sigmask (SIG_BLOCK + SIG_UNBLOCK + SIG_SETMASK, NULL, &sigs); |
44 /* Direct return of the error number; i.e. not using -1 and errno, | 44 /* Direct return of the error number; i.e. not using -1 and errno, |
45 is the actual documented behavior. */ | 45 is the actual documented behavior. */ |
46 if (retcode == ENOSYS) | 46 if (retcode == ENOSYS) |
47 printf ("ENOSYS\n"); | 47 printf ("ENOSYS\n"); |
48 | 48 |
49 printf ("xyzzy\n"); | 49 printf ("xyzzy\n"); |
50 return 0; | 50 return 0; |
51 } | 51 } |
OLD | NEW |