]> git.proxmox.com Git - mirror_edk2.git/blame - StdLib/Include/sys/signal.h
Add Socket Libraries.
[mirror_edk2.git] / StdLib / Include / sys / signal.h
CommitLineData
2aa62f2b 1/**\r
d7ce7006 2Copyright (c) 2010 - 2011, Intel Corporation. All rights reserved.<BR>\r
2aa62f2b 3This program and the accompanying materials are licensed and made available under\r
4the terms and conditions of the BSD License that accompanies this distribution.\r
5The full text of the license may be found at\r
6http://opensource.org/licenses/bsd-license.php.\r
7\r
8THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
9WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
10\r
11**/\r
12#ifndef _SYS_SIGNAL_H\r
13#define _SYS_SIGNAL_H\r
14#include <sys/EfiCdefs.h>\r
15#include <machine/signal.h>\r
16\r
53e1e5c6 17enum {\r
18 __SigInt = 1,\r
19 __SigIll,\r
20 __SigAbrt,\r
21 __SigFpe,\r
22 __SigSegv,\r
23 __SigTerm,\r
24 __SigBreak,\r
d7ce7006 25 __SigAlrm,\r
26 __SigVtAlrm,\r
27 __SigProf,\r
28 __SigUsr1,\r
29 __SigUsr2,\r
30 __SigWinch,\r
31 __SigPipe,\r
32 __SigQuit,\r
53e1e5c6 33 __Sig_Last\r
34};\r
35\r
2aa62f2b 36/** The type of a signal handler function. **/\r
37typedef void __sighandler_t(int);\r
38\r
39/** The signal function associates a "signal handler" with a signal number.\r
40\r
41 For historical reasons; programs expect signal to be declared\r
42 in <sys/signal.h>.\r
43\r
44 @param[in] sig Signal number that function is to be associated with.\r
45 @param[in] function The "handler" function to be associated with signal sig.\r
46\r
47 @return If the request can be honored, the signal function returns the\r
48 value of func for the most recent successful call to signal for\r
49 the specified signal sig. Otherwise, a value of SIG_ERR is\r
50 returned and a positive value is stored in errno.\r
51 */\r
52__BEGIN_DECLS\r
53__sighandler_t *signal(int sig, __sighandler_t *func);\r
54__END_DECLS\r
55\r
56#endif /* _SYS_SIGNAL_H */\r