You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by rb...@locus.apache.org on 2000/10/19 03:24:12 UTC

cvs commit: apache-2.0/src/main http_connection.c

rbb         00/10/18 18:24:12

  Modified:    src/main http_connection.c
  Log:
  Change some of the BUFF calls to direct calls to the socket.
  
  Revision  Changes    Path
  1.54      +4 -4      apache-2.0/src/main/http_connection.c
  
  Index: http_connection.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/main/http_connection.c,v
  retrieving revision 1.53
  retrieving revision 1.54
  diff -u -r1.53 -r1.54
  --- http_connection.c	2000/10/18 19:12:08	1.53
  +++ http_connection.c	2000/10/19 01:24:10	1.54
  @@ -176,7 +176,7 @@
        * to the peer.
        */
       
  -    if (ap_bshutdown(c->client, 1) != APR_SUCCESS || c->aborted) {
  +    if (apr_shutdown(c->client_socket, 1) != APR_SUCCESS || c->aborted) {
           ap_bclose(c->client);
           return;
       }
  @@ -186,9 +186,9 @@
        */
       
       start = apr_now();
  -    timeout = MAX_SECS_TO_LINGER;
  +    timeout = MAX_SECS_TO_LINGER * APR_USEC_PER_SEC;
       for (;;) {
  -        ap_bsetopt(c->client, BO_TIMEOUT, &timeout);
  +        apr_setsocketopt(c->client_socket, BO_TIMEOUT, timeout);
           rc = ap_bread(c->client, dummybuf, sizeof(dummybuf),
                         &nbytes);
           if (rc != APR_SUCCESS || nbytes == 0) break;
  @@ -198,7 +198,7 @@
           if (timeout >= MAX_SECS_TO_LINGER) break;
   
           /* figure out the new timeout */
  -        timeout = MAX_SECS_TO_LINGER - timeout;
  +        timeout = (MAX_SECS_TO_LINGER - timeout) * APR_USEC_PER_SEC;
       }
   
       ap_bclose(c->client);