siglist.c revision 218285
118334Speter/* 218334Speter * Copyright (c) 1983, 1993 318334Speter * The Regents of the University of California. All rights reserved. 490075Sobrien * 5132718Skan * Redistribution and use in source and binary forms, with or without 618334Speter * modification, are permitted provided that the following conditions 790075Sobrien * are met: 818334Speter * 1. Redistributions of source code must retain the above copyright 990075Sobrien * notice, this list of conditions and the following disclaimer. 1090075Sobrien * 2. Redistributions in binary form must reproduce the above copyright 1190075Sobrien * notice, this list of conditions and the following disclaimer in the 1290075Sobrien * documentation and/or other materials provided with the distribution. 1318334Speter * 4. Neither the name of the University nor the names of its contributors 1490075Sobrien * may be used to endorse or promote products derived from this software 1590075Sobrien * without specific prior written permission. 1690075Sobrien * 1790075Sobrien * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 1818334Speter * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1918334Speter * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 2090075Sobrien * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 21169689Skan * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22169689Skan * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 2318334Speter * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 2418334Speter * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25132718Skan * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 2650397Sobrien * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27132718Skan * SUCH DAMAGE. 28132718Skan */ 2918334Speter 3018334Speter#if defined(LIBC_SCCS) && !defined(lint) 3190075Sobrienstatic char sccsid[] = "@(#)siglist.c 8.1 (Berkeley) 6/4/93"; 3290075Sobrien#endif /* LIBC_SCCS and not lint */ 3318334Speter#include <sys/cdefs.h> 3490075Sobrien__FBSDID("$FreeBSD: head/lib/libc/gen/siglist.c 218285 2011-02-04 16:40:50Z jilles $"); 3590075Sobrien 3618334Speter#include <signal.h> 3718334Speter 3818334Speterconst char *const sys_signame[NSIG] = { 3918334Speter "Signal 0", 4090075Sobrien "HUP", /* SIGHUP */ 4190075Sobrien "INT", /* SIGINT */ 4250397Sobrien "QUIT", /* SIGQUIT */ 43132718Skan "ILL", /* SIGILL */ 44132718Skan "TRAP", /* SIGTRAP */ 45132718Skan "ABRT", /* SIGABRT */ 46132718Skan "EMT", /* SIGEMT */ 47132718Skan "FPE", /* SIGFPE */ 4850397Sobrien "KILL", /* SIGKILL */ 4918334Speter "BUS", /* SIGBUS */ 5050397Sobrien "SEGV", /* SIGSEGV */ 5190075Sobrien "SYS", /* SIGSYS */ 52132718Skan "PIPE", /* SIGPIPE */ 5318334Speter "ALRM", /* SIGALRM */ 5490075Sobrien "TERM", /* SIGTERM */ 5590075Sobrien "URG", /* SIGURG */ 5690075Sobrien "STOP", /* SIGSTOP */ 5790075Sobrien "TSTP", /* SIGTSTP */ 5818334Speter "CONT", /* SIGCONT */ 5990075Sobrien "CHLD", /* SIGCHLD */ 6090075Sobrien "TTIN", /* SIGTTIN */ 6118334Speter "TTOU", /* SIGTTOU */ 6290075Sobrien "IO", /* SIGIO */ 6318334Speter "XCPU", /* SIGXCPU */ 6490075Sobrien "XFSZ", /* SIGXFSZ */ 6590075Sobrien "VTALRM", /* SIGVTALRM */ 6690075Sobrien "PROF", /* SIGPROF */ 6790075Sobrien "WINCH", /* SIGWINCH */ 6890075Sobrien "INFO", /* SIGINFO */ 6990075Sobrien "USR1", /* SIGUSR1 */ 7090075Sobrien "USR2" /* SIGUSR2 */ 7118334Speter}; 7290075Sobrien 7390075Sobrienconst char *const sys_siglist[NSIG] = { 7490075Sobrien "Signal 0", 7518334Speter "Hangup", /* SIGHUP */ 7690075Sobrien "Interrupt", /* SIGINT */ 7790075Sobrien "Quit", /* SIGQUIT */ 7890075Sobrien "Illegal instruction", /* SIGILL */ 7918334Speter "Trace/BPT trap", /* SIGTRAP */ 8018334Speter "Abort trap", /* SIGABRT */ 8190075Sobrien "EMT trap", /* SIGEMT */ 8218334Speter "Floating point exception", /* SIGFPE */ 8390075Sobrien "Killed", /* SIGKILL */ 84132718Skan "Bus error", /* SIGBUS */ 8590075Sobrien "Segmentation fault", /* SIGSEGV */ 8690075Sobrien "Bad system call", /* SIGSYS */ 8790075Sobrien "Broken pipe", /* SIGPIPE */ 8890075Sobrien "Alarm clock", /* SIGALRM */ 8990075Sobrien "Terminated", /* SIGTERM */ 9090075Sobrien "Urgent I/O condition", /* SIGURG */ 9190075Sobrien "Suspended (signal)", /* SIGSTOP */ 9290075Sobrien "Suspended", /* SIGTSTP */ 9390075Sobrien "Continued", /* SIGCONT */ 9490075Sobrien "Child exited", /* SIGCHLD */ 9518334Speter "Stopped (tty input)", /* SIGTTIN */ 9618334Speter "Stopped (tty output)", /* SIGTTOU */ 9790075Sobrien "I/O possible", /* SIGIO */ 9890075Sobrien "Cputime limit exceeded", /* SIGXCPU */ 9990075Sobrien "Filesize limit exceeded", /* SIGXFSZ */ 10090075Sobrien "Virtual timer expired", /* SIGVTALRM */ 101132718Skan "Profiling timer expired", /* SIGPROF */ 10290075Sobrien "Window size changes", /* SIGWINCH */ 10390075Sobrien "Information request", /* SIGINFO */ 10490075Sobrien "User defined signal 1", /* SIGUSR1 */ 105169689Skan "User defined signal 2" /* SIGUSR2 */ 106169689Skan}; 10790075Sobrienconst int sys_nsig = sizeof(sys_siglist) / sizeof(sys_siglist[0]); 10890075Sobrien