1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
|
/* @(#) network.h 1.11 @(#) */
/***************************************************************\
* Copyright (c) 1999 First Step Internet Services, Inc.
* All Rights Reserved
*
* Module: Network
\***************************************************************/
#ifndef _KOALAMUD_NETWORK_H
#define _KOALAMUD_NETWORK_H "@(#) nitehawk@winghove.1ststep.net|include/network.h|20000307194807|49841 @(#)"
#include "koalatypes.h"
#include "llist.h"
/* Types */
#define MAGICLEN 30
typedef struct TAG_DAEMONMAGIC
{
char daemonmagic[MAGICLEN];
char clientmagic[MAGICLEN];
char zonemagic[MAGICLEN];
char hubmagic[MAGICLEN];
} daemonmagic;
extern daemonmagic magic;
/* Prototypes */
koalaerror netstartup(void);
koalaerror netlisten(listnodeptr list, char *bindaddr, int port);
koalaerror ksetsocketopts(int sock);
koalaerror netaccept(pdescriptor desc, pdescriptor *newconnection);
koalaerror netclose(pdescriptor desc);
koalaerror netread(pdescriptor desc, char *buffer, unsigned int *len);
koalaerror netwrite(pdescriptor desc, char *data, unsigned int len);
koalaerror netuplink(pdescriptor uplink, char *bindaddr, int port);
#endif
|