summaryrefslogtreecommitdiff
path: root/include/wait.h
blob: af8a979dd4d46df0f4a3d99cacc1172e7b5a4993 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#ifndef WAIT_H
#define WAIT_H

/**
	@file wait.h
	@author djb
	@source s/qmail
*/

int wait_pid(int *, int);
int wait_nohang(int *);
int wait_stop();
int wait_stopnohang();

#define wait_crashed(w)  ((w) & 127)
#define wait_exitcode(w) ((w) >> 8)
#define wait_stopsig(w)  ((w) >> 8)
#define wait_stopped(w)  (((w) & 127) == 127)

#endif