00001 #ifndef __APP_CONFIG_H__
00002 #define __APP_CONFIG_H__
00003
00004 #define MAXPENDING 10
00005 #define MAXCLIENTS 1000
00006 #define READBUFSIZE 2048
00007 #define DEFAULTPORT 8801
00008 #define DEFAULTPATH "logfiles"
00009 #define LOGNAMEPATTERN "log-%Y-%m-%d_%Hh"
00010
00011 #undef MAX
00012 #define MAX(x,y) ((x) > (y) ? (x) : (y))
00013
00014 #undef MIN
00015 #define MIN(x,y) ((x) < (y) ? (x) : (y))
00016
00017 typedef struct {
00018 unsigned char verbose;
00019 unsigned char doDaemon;
00020 unsigned int maxPending;
00021 unsigned int port;
00022 char logPath[513];
00023 char namePat[513];
00024 } tAppConfig;
00025
00026 int
00027 handleCmdLine(tAppConfig * config, int argc, char *argv[]);
00028
00029 #endif // __APP_CONFIG_H__