void _fastcall _near dfputs(char _near *);
void _fastcall _near dfputs(char _near *);
void _fastcall _near printn(unsigned short);
void _fastcall _near printd(unsigned short);
int _near net_socket(int, struct net_addr _far *);
void _near net_perror(char _near *);
int _fastcall _near convert_error(int);
void _fastcall _near leave(int);

int _fastcall _near tcpopen_init(int, int _near *, void _far *);
int _fastcall _near tcpopen_shutdown(int, int _near *, void _far *);
int _fastcall _near tcpopen_socket(int, int _near *, void _far *);
int _fastcall _near tcpopen_info(int, int _near *, void _far *);
int _fastcall _near tcpopen_accept(int, int _near *, void _far *);
int _fastcall _near tcpopen_drain(int, int _near *, void _far *);
int _fastcall _near tcpopen_release(int, int _near *, void _far *);
int _fastcall _near tcpopen_eof(int, int _near *, void _far *);
int _fastcall _near tcpopen_read(int, int _near *, void _far *);
int _fastcall _near tcpopen_write(int, int _near *, void _far *);
int _fastcall _near tcpopen_recv(int, int _near *, void _far *);
int _fastcall _near tcpopen_sendto(int, int _near *, void _far *);
int _fastcall _near tcpopen_select(int, int _near *, void _far *);

#undef htons
#undef ntohs
#define htons(x) ((u_int)((u_char)(x) << 8) | (u_char)((unsigned int)(x) >> 8))
#define ntohs(x) ((u_int)((u_char)(x) << 8) | (u_char)((unsigned int)(x) >> 8))
