apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From traw...@apache.org
Subject cvs commit: apr/network_io/win32 sockets.c
Date Sat, 31 Mar 2001 18:58:17 GMT
trawick     01/03/31 10:58:17

  Modified:    network_io/win32 sockets.c
  Log:
  When allocating local and remote sockaddrs with a new socket,
  make sure to fill out the pool field in them.  Otherwise,
  certain operations can segfault.
  
  Revision  Changes    Path
  1.52      +2 -0      apr/network_io/win32/sockets.c
  
  Index: sockets.c
  ===================================================================
  RCS file: /home/cvs/apr/network_io/win32/sockets.c,v
  retrieving revision 1.51
  retrieving revision 1.52
  diff -u -r1.51 -r1.52
  --- sockets.c	2001/02/16 04:16:04	1.51
  +++ sockets.c	2001/03/31 18:58:16	1.52
  @@ -108,8 +108,10 @@
       (*new)->cntxt = p;
       (*new)->local_addr = (apr_sockaddr_t *)apr_pcalloc((*new)->cntxt,
                                                          sizeof(apr_sockaddr_t));
  +    (*new)->local_addr->pool = p;
       (*new)->remote_addr = (apr_sockaddr_t *)apr_pcalloc((*new)->cntxt,
                                                           sizeof(apr_sockaddr_t));
  +    (*new)->remote_addr->pool = p;
   }
   
   APR_DECLARE(apr_status_t) apr_socket_create(apr_socket_t **new, int ofamily,
  
  
  

Mime
View raw message