
#define FD_ISSET(d,set)	((set)->fds_bits[((d)/(8*sizeof(long)))]&amp (1<<((d)%(8*sizeof(long)))))
#define FD_CLR(d,set)	((set)->fds_bits[((d)/(8*sizeof(long)))]&amp =~(1<<((d)%(8*sizeof(long)))))
#define FD_SET(d,set)	((set)->fds_bits[((d)/(8*sizeof(long)))]|=(1<<((d)%(8*sizeof(long)))))
#define FALSE	0
#define TRUE	1
#define FD_SETSIZE	1024
#define FD_ZERO(fdsetp)	bzero(fdsetp, sizeof(*(fdsetp)))

typedef signed char int8_t;
typedef short int16_t;
typedef int int32_t;
typedef unsigned char u_int8_t;
typedef unsigned short u_int16_t;
typedef unsigned int u_int32_t;
typedef unsigned int uid_t;
typedef int pid_t;
typedef unsigned long off_t;
typedef int key_t;
typedef long suseconds_t;
typedef unsigned int u_int;
typedef struct
{
  int __val[2];
}
fsid_t;
typedef unsigned int useconds_t;
typedef unsigned long blksize_t;
typedef long fd_mask;
typedef int timer_t;
typedef int clockid_t;

typedef unsigned int id_t;

typedef unsigned long long ino64_t;
typedef long long loff_t;
typedef unsigned long blkcnt_t;
typedef unsigned long fsblkcnt_t;
typedef unsigned long fsfilcnt_t;
typedef unsigned long long blkcnt64_t;
typedef unsigned long long fsblkcnt64_t;
typedef unsigned long long fsfilcnt64_t;
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned long u_long;

typedef unsigned long ino_t;
typedef unsigned int gid_t;
typedef unsigned long long dev_t;
typedef unsigned int mode_t;
typedef unsigned long nlink_t;
typedef char *caddr_t;

typedef struct
{
  unsigned long fds_bits[__FDSET_LONGS];
}
fd_set;

typedef long clock_t;
typedef long time_t;
