- added a bunch of null terminations to all char buffers in network protocol

This commit is contained in:
Mark Vejvoda
2010-08-20 23:53:10 +00:00
parent ff7828fa6f
commit 07cbcc0bec
6 changed files with 61 additions and 20 deletions

View File

@@ -1702,7 +1702,10 @@ Socket *ServerSocket::accept() {
struct sockaddr_in cli_addr;
socklen_t clilen = sizeof(cli_addr);
char client_host[100]="";
MutexSafeWrapper safeMutex(&dataSynchAccessor);
PLATFORM_SOCKET newSock= ::accept(sock, (struct sockaddr *) &cli_addr, &clilen);
safeMutex.ReleaseLock();
if(isSocketValid(&newSock) == false)
{
char szBuf[1024]="";