httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marc Slemko <ma...@znep.com>
Subject Re: Hold the Presses! Possible problem in 1.2b5
Date Sun, 26 Jan 1997 20:40:29 GMT
I think the following should fix it.

BTW, Apache won't compile with HAVE_SNPRINTF defined as things are now
because not everything includes conf.h.  Probably not worth worrying about
for this beta?  Or is it.

Index: http_main.c
===================================================================
RCS file: /export/home/cvs/apache/src/http_main.c,v
retrieving revision 1.113
diff -c -r1.113 http_main.c
*** 1.113	1997/01/25 22:37:11
--- http_main.c	1997/01/26 20:38:49
***************
*** 1607,1613 ****
                      clen = sizeof(sa_client);
                      csd  = accept(sd, &sa_client, &clen);
                  } while (csd < 0 && errno == EINTR);
!                 if (csd < 0) break;
  		log_unixerr("accept", "(client socket)", NULL, server_conf);
  	    }
  	}
--- 1607,1613 ----
                      clen = sizeof(sa_client);
                      csd  = accept(sd, &sa_client, &clen);
                  } while (csd < 0 && errno == EINTR);
!                 if (csd > 0) break;
  		log_unixerr("accept", "(client socket)", NULL, server_conf);
  	    }
  	}


On Sun, 26 Jan 1997, Randy Terbush wrote:

> 
> I've found that the changes in the patch submitted by Roy which
> changed the loop in child_main() around the accept fails to
> serve a request on my FreeBSD 2.1.6 server.
> 
> However, it seems to work fine on a FreeBSD 2.2 machine.
> 
> [Sun Jan 26 14:19:21 1997] accept: (client socket): Undefined error: 0
> 
> Looks like this is the code in question. Reversing that patch solves
> the problem.
> 
>                 do {
>                     clen = sizeof(sa_client);
>                     csd  = accept(sd, &sa_client, &clen);
>                 } while (csd < 0 && errno == EINTR);
>                 if (csd < 0) break;
> 		log_unixerr("accept", "(client socket)", NULL, server_conf);
> 


Mime
View raw message