server & client test

This commit is contained in:
Carl-Benedikt Krüger 2011-07-12 13:33:51 +02:00
parent 96d938286e
commit 73118044dc

View file

@ -147,14 +147,14 @@ int server_init(Server* srv, unsigned short Port, unsigned int dwMaxConnections)
srv->_OnDisconnect=0;
srv->_OnWrite=0;
// Allocate needed Memory
// Allocate needed Memory
srv->sConnections=(SOCKET*)kmalloc(sizeof(SOCKET)*srv->dwConnections);
srv->ConnectionsAddr =(struct sockaddr_in*) kmalloc(sizeof(struct sockaddr_in)*dwMaxConnections);
srv->bThreads = (tid_t*)kmalloc(sizeof(tid_t)*dwMaxConnections);
if (!srv->sConnections || !srv->ConnectionsAddr || !srv->bThreads)
{
kprintf("low on mem");
kprintf("low on mem -%d- -%d- -%d-");
return -1;
}