#include #include #include #include #include #include #ifdef WIN32 #include #include /* http://predef.sourceforge.net/precomp.html */ #if (!((defined(_MSC_VER)) && (_MSC_VER < 1300))) #include #endif #include #else #include #include #endif #include "version.h" #include "ClientStateAndData.h" //#include "hca.h" #include "hcb.h" #include "hcb.h" #include "ClientStateAndData.h" #include "ClientServerMapper.h" /* Macro for debug printouts */ #ifdef DEBUG #define D(x) x #else #define D(x) #endif ClientServerMapper::ClientServerMapper() { for (unsigned int i=0; iprocess(); if (r==-1) { D(fprintf(stderr,"one client disconnected\n");) delete c; clientStateAndData[i]=NULL; } else if (r==-2) { D(fprintf(stderr,"client gave shutdown server command\n");) delete c; clientStateAndData[i]=NULL; return -2; } else if (r<0) { D(fprintf(stderr,"unknown error from client process\n");) } } } return 0; } ClientStateAndData *clientStateAndData[32];