Commit | Line | Data |
---|---|---|
6941fcc4 EA |
1 | /* |
2 | ** USEFUL.H -- Some useful stuff. | |
916b3375 | 3 | ** |
62fff4f9 | 4 | ** @(#)useful.h 3.5 %G% |
6941fcc4 EA |
5 | */ |
6 | ||
1146de6b EA |
7 | # ifndef makedev |
8 | # include <sys/types.h> | |
9 | # endif | |
10 | ||
11 | /* support for bool type */ | |
12 | typedef char bool; | |
6941fcc4 EA |
13 | # define TRUE 1 |
14 | # define FALSE 0 | |
15 | ||
16 | # ifndef NULL | |
17 | # define NULL 0 | |
18 | # endif NULL | |
21d76258 | 19 | |
1146de6b | 20 | /* bit hacking */ |
21d76258 | 21 | # define bitset(bit, word) ((word) & (bit)) |
29871fef EA |
22 | |
23 | /* define the types of some common functions */ | |
24 | extern char *strcpy(); | |
25 | extern char *strcat(); | |
26 | extern char *malloc(); | |
27 | extern char *index(), *rindex(); | |
28 | extern int errno; | |
29 | extern char *sprintf(); | |
62fff4f9 | 30 | extern time_t time(); |
29871fef EA |
31 | extern char *ctime(); |
32 | # ifndef V6 | |
33 | extern char *getenv(); | |
b14547d5 EA |
34 | # else V6 |
35 | typedef char *u_short; | |
36 | typedef long u_long; | |
37 | typedef char u_char; | |
38 | typedef int void; | |
39 | # endif V6 |