blob: bbe8a8fe09de7133ac7f67b01aae55d78e1b9e28 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
#ifndef __WAIT_H
#define __WAIT_H
#define WCONTINUED 0x00000008
#define WNOHANG 0x00000001
#define WUNTRACED 0x00000002
#define WCOREDUMP(__s) ((__s) & 0x80)
#define WIFCONTINUED(__s) ((__s) == 0xffff)
#define WIFEXITED(__s) (!WTERMSIG(__s))
#define WIFSIGNALED(__s) (((s) & 0xffff) - 1U < 0xffu)
#define WIFSTOPPED(__s) ((short)((((__s) & 0xffff) * 0x10001U) >> 8) > 0x7f00)
#define WSTOPSIG(__s) WEXITSTATUS(__s)
#define WTERMSIG(__s) ((__s) & 0x7f)
#define WEXITED
#define WNOWAIT
#define WSTOPPED
typedef __UINT32_TYPE__ id_t;
typedef __INT64_TYPE__ pid_t;
typedef __UINT32_TYPE__ uid_t;
union sigval {
int sival_int;
void *sival_ptr;
};
typedef struct {
int si_signo;
int si_code;
int si_errno;
pid_t si_pid;
uid_t si_uid;
void *si_addr;
int si_status;
union sigval si_value;
} siginfo_t;
typedef enum { P_ALL = 0, P_PID = 1, P_PGID = 2 } idtype_t;
pid_t wait(int *);
int waitid(idtype_t, id_t, siginfo_t *, int);
pid_t waitpid(pid_t, int *, int);
#endif
|