]> git.proxmox.com Git - mirror_edk2.git/blob - StdLib/Include/sys/signal.h
Standard Libraries for EDK II.
[mirror_edk2.git] / StdLib / Include / sys / signal.h
1 /**
2 Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
3 This program and the accompanying materials are licensed and made available under
4 the terms and conditions of the BSD License that accompanies this distribution.
5 The full text of the license may be found at
6 http://opensource.org/licenses/bsd-license.php.
7
8 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
9 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
10
11 **/
12 #ifndef _SYS_SIGNAL_H
13 #define _SYS_SIGNAL_H
14 #include <sys/EfiCdefs.h>
15 #include <machine/signal.h>
16
17 /** The type of a signal handler function. **/
18 typedef void __sighandler_t(int);
19
20 /** The signal function associates a "signal handler" with a signal number.
21
22 For historical reasons; programs expect signal to be declared
23 in <sys/signal.h>.
24
25 @param[in] sig Signal number that function is to be associated with.
26 @param[in] function The "handler" function to be associated with signal sig.
27
28 @return If the request can be honored, the signal function returns the
29 value of func for the most recent successful call to signal for
30 the specified signal sig. Otherwise, a value of SIG_ERR is
31 returned and a positive value is stored in errno.
32 */
33 __BEGIN_DECLS
34 __sighandler_t *signal(int sig, __sighandler_t *func);
35 __END_DECLS
36
37 #endif /* _SYS_SIGNAL_H */