00001 #ifndef __SERVER_H__
00002 #define __SERVER_H__
00003
00004 #include <stdio.h>
00005 #include <sys/select.h>
00006
00007 #include "client.h"
00008
00009 typedef struct {
00010 int servSock;
00011 tClient clients[FD_SETSIZE];
00012 unsigned int maxFd;
00013 fd_set socks;
00014 char logPath[512];
00015 char namePat[512];
00016 FILE * wHandle;
00017 } tServer;
00018
00019
00020 void serverShutdown(tServer * server);
00021 void serverInit(
00022 tServer * server,
00023 unsigned int port,
00024 unsigned int pending,
00025 const char * logPath,
00026 const char * namePat);
00027 void serverRun(tServer * server);
00028
00029 #endif // __SERVER_H__