You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by st...@apache.org on 2002/02/09 15:51:30 UTC

cvs commit: apache-1.3/src/main buff.c

stoddard    02/02/09 06:51:30

  Modified:    src      CHANGES
               src/main buff.c
  Log:
  Win32: Eliminate blocking network i/o in the Windows code paths. In practice
  only sends() were ever blocking. That any network i/o was ever blocking
  could be considered a bug in Apache.
  
  This patch seems to work around a bug in WinXP that causes network write
  data corruption. The bug appears to be tickled by the combined use of
  WSADuplicateSocket and blocking sends().  Allan Edwards is submitting a
  bug report to Microsoft.
  
  Revision  Changes    Path
  1.1771    +6 -1      apache-1.3/src/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /home/cvs/apache-1.3/src/CHANGES,v
  retrieving revision 1.1770
  retrieving revision 1.1771
  diff -u -r1.1770 -r1.1771
  --- CHANGES	6 Feb 2002 15:59:27 -0000	1.1770
  +++ CHANGES	9 Feb 2002 14:51:29 -0000	1.1771
  @@ -1,5 +1,10 @@
   Changes with Apache 1.3.24
  -
  +  *) Win32: Work around a bug in Windows XP that caused data
  +     corruption on writes to the network. The WinXP bug
  +     is tickled by the combined use of WSADuplicateSocket 
  +     and blocking send() calls.
  +     [Bill Stoddard, Bill Rowe, Allan Edwards, Szabolcs Szakacsits]
  +     
     *) Add 'IgnoreCase' keyword to the IndexOptions directive;
        if active, upper- and lower-case letters are insignificant
        in ordering.  In other words, all A* and a* files will be
  
  
  
  1.107     +2 -4      apache-1.3/src/main/buff.c
  
  Index: buff.c
  ===================================================================
  RCS file: /home/cvs/apache-1.3/src/main/buff.c,v
  retrieving revision 1.106
  retrieving revision 1.107
  diff -u -r1.106 -r1.107
  --- buff.c	20 Jan 2002 22:45:14 -0000	1.106
  +++ buff.c	9 Feb 2002 14:51:30 -0000	1.107
  @@ -137,8 +137,7 @@
       int rv;
       int retry;
   
  -    if (!(tv.tv_sec = ap_check_alarm()))
  -	return (send(sock, buf, len, flags));
  +    tv.tv_sec = ap_check_alarm();
   
       rv = ioctlsocket(sock, FIONBIO, (u_long*)&iostate);
       iostate = 0;
  @@ -204,8 +203,7 @@
       int rv;
       int retry;
   
  -    if (!(tv.tv_sec = ap_check_alarm()))
  -	return (recv(sock, buf, len, flags));
  +    tv.tv_sec = ap_check_alarm();
   
       rv = ioctlsocket(sock, FIONBIO, (u_long*)&iostate);
       iostate = 0;