31 |
|
#include "fdlist.h" |
32 |
|
|
33 |
|
/* Type of IO */ |
34 |
< |
#define COMM_SELECT_READ 1 |
35 |
< |
#define COMM_SELECT_WRITE 2 |
34 |
> |
enum |
35 |
> |
{ |
36 |
> |
COMM_SELECT_READ = 1, |
37 |
> |
COMM_SELECT_WRITE = 2 |
38 |
> |
}; |
39 |
|
|
40 |
|
/* How long can comm_select() wait for network events [milliseconds] */ |
41 |
< |
#define SELECT_DELAY 500 |
41 |
> |
enum { SELECT_DELAY = 500 }; |
42 |
|
|
43 |
|
struct Client; |
44 |
|
struct MaskItem; |
56 |
|
extern void comm_checktimeouts(void *); |
57 |
|
extern void comm_connect_tcp(fde_t *, const char *, unsigned short, struct sockaddr *, int, |
58 |
|
void (struct _fde *, int, void *), void *, int, int); |
59 |
< |
extern const char *comm_errstr(int status); |
60 |
< |
extern int comm_open(fde_t *F, int family, int sock_type, int proto, |
61 |
< |
const char *note); |
59 |
< |
extern int comm_accept(struct Listener *, struct irc_ssaddr *pn); |
59 |
> |
extern const char *comm_errstr(int); |
60 |
> |
extern int comm_open(fde_t *, int, int, int, const char *); |
61 |
> |
extern int comm_accept(struct Listener *, struct irc_ssaddr *); |
62 |
|
|
63 |
|
/* These must be defined in the network IO loop code of your choice */ |
64 |
|
extern void init_netio(void); |