httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r..@apache.org
Subject cvs commit: httpd-2.0/server listen.c
Date Sun, 07 Jan 2001 05:51:23 GMT
rbb         01/01/06 21:51:23

  Modified:    server   listen.c
  Log:
  Stop leaking sockets.  This is a minimal leak, but it was there.
  Basically, we were creating a socket_t, but never assigning a port or
  IP address to it.  We then re-read the config file, and search the
  list of allocated sockets for the socket that we have already allocated
  for this port, but we never find the port and address, because we never
  stored them in the socket_t.  This was keeping the Listen directive from
  working properly.
  
  Revision  Changes    Path
  1.46      +3 -0      httpd-2.0/server/listen.c
  
  Index: listen.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/server/listen.c,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -r1.45 -r1.46
  --- listen.c	2001/01/02 01:34:05	1.45
  +++ listen.c	2001/01/07 05:51:23	1.46
  @@ -252,6 +252,9 @@
                        "alloc_listener: failed to get a socket for %s", addr);
           return;
       }
  +    apr_get_sockaddr(&sa, APR_LOCAL, new->sd);
  +    apr_set_port(sa, port);
  +    apr_set_ipaddr(sa, addr);
       new->next = ap_listeners;
       ap_listeners = new;
   }
  
  
  

Mime
View raw message