You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by tr...@apache.org on 2011/04/03 19:50:18 UTC
svn commit: r1088352 - /apr/apr/trunk/network_io/win32/sockets.c
Author: trawick
Date: Sun Apr 3 17:50:18 2011
New Revision: 1088352
URL: http://svn.apache.org/viewvc?rev=1088352&view=rev
Log:
Windows: Save a call to getpeername() when trying to retrieve the
remote address of a socket created by apr_socket_accept()
Modified:
apr/apr/trunk/network_io/win32/sockets.c
Modified: apr/apr/trunk/network_io/win32/sockets.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/network_io/win32/sockets.c?rev=1088352&r1=1088351&r2=1088352&view=diff
==============================================================================
--- apr/apr/trunk/network_io/win32/sockets.c (original)
+++ apr/apr/trunk/network_io/win32/sockets.c Sun Apr 3 17:50:18 2011
@@ -252,6 +252,8 @@ APR_DECLARE(apr_status_t) apr_socket_acc
/* XXX next line looks bogus w.r.t. AF_INET6 support */
(*new)->remote_addr->salen = sizeof((*new)->remote_addr->sa);
memcpy (&(*new)->remote_addr->sa, &sa, salen);
+ (*new)->remote_addr_unknown = 0;
+
*(*new)->local_addr = *sock->local_addr;
/* The above assignment just overwrote the pool entry. Setting the local_addr