Mailing List Archive

cvs commit: apache/src http_main.c
ben 97/06/29 08:17:49

Modified: src http_main.c
Log:
Check error code from accept() on Win32 correctly.
Submitted by: Paul Sutton

Revision Changes Path
1.167 +1 -1 apache/src/http_main.c

Index: http_main.c
===================================================================
RCS file: /export/home/cvs/apache/src/http_main.c,v
retrieving revision 1.166
retrieving revision 1.167
diff -C3 -r1.166 -r1.167
*** http_main.c 1997/06/29 00:03:17 1.166
--- http_main.c 1997/06/29 15:17:48 1.167
***************
*** 3176,3182 ****
clen = sizeof(sa_client);
csd = accept(sd, (struct sockaddr *)&sa_client, &clen);
#ifdef WIN32
! if(csd == SOCKET_ERROR)
{
csd = -1;
errno = WSAGetLastError() - WSABASEERR;
--- 3176,3182 ----
clen = sizeof(sa_client);
csd = accept(sd, (struct sockaddr *)&sa_client, &clen);
#ifdef WIN32
! if(csd == INVALID_SOCKET)
{
csd = -1;
errno = WSAGetLastError() - WSABASEERR;