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 2004/05/22 00:21:13 UTC
cvs commit: apr/network_io/win32 sockets.c
trawick 2004/05/21 15:21:13
Modified: . CHANGES
network_io/win32 sockets.c
Log:
Fix stack overflow with IPv6 apr_socket_accept() on Win32.
PR: 28471
Submitted by: inoue <inoue ariel-networks.com>
Reviewed by: Jeff Trawick
Revision Changes Path
1.469 +3 -0 apr/CHANGES
Index: CHANGES
===================================================================
RCS file: /home/cvs/apr/CHANGES,v
retrieving revision 1.468
retrieving revision 1.469
diff -u -r1.468 -r1.469
--- CHANGES 21 May 2004 22:11:27 -0000 1.468
+++ CHANGES 21 May 2004 22:21:13 -0000 1.469
@@ -7,6 +7,9 @@
Changes with APR 1.0
+ *) Fix stack overflow with IPv6 apr_socket_accept() on Win32.
+ PR 28471. [inoue <inoue ariel-networks.com>]
+
*) Add new functions apr_signal_block, apr_signal_unblock to block/unblock
the delivery of a particular signal. [Madhusudan Mathihalli]
1.105 +4 -0 apr/network_io/win32/sockets.c
Index: sockets.c
===================================================================
RCS file: /home/cvs/apr/network_io/win32/sockets.c,v
retrieving revision 1.104
retrieving revision 1.105
diff -u -r1.104 -r1.105
--- sockets.c 13 Feb 2004 09:38:33 -0000 1.104
+++ sockets.c 21 May 2004 22:21:13 -0000 1.105
@@ -212,7 +212,11 @@
apr_socket_t *sock, apr_pool_t *p)
{
SOCKET s;
+#if APR_HAVE_IPV6
+ struct sockaddr_storage sa;
+#else
struct sockaddr sa;
+#endif
int salen = sizeof(sock->remote_addr->sa);
/* Don't allocate the memory until after we call accept. This allows