From: Jeff Trawick Date: Tue, 31 Jul 2012 23:19:56 +0000 (+0000) Subject: initialize the protocol field when manufacturing an apr socket X-Git-Tag: 2.5.0-alpha~6547 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7f40cfd3eec10d3e0e508c47a067534f16cbd67b;p=thirdparty%2Fapache%2Fhttpd.git initialize the protocol field when manufacturing an apr socket lest accidential autodata contents leak into the apr_socket_t (this doesn't address any known problem symptom) git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1367819 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/server/mpm/winnt/child.c b/server/mpm/winnt/child.c index 0b52775414f..f55ab111403 100644 --- a/server/mpm/winnt/child.c +++ b/server/mpm/winnt/child.c @@ -686,11 +686,12 @@ reinit: /* target of data or connect upon too many AcceptEx failures */ } } - sockinfo.os_sock = &context->accept_socket; - sockinfo.local = context->sa_server; - sockinfo.remote = context->sa_client; - sockinfo.family = context->sa_server->sa_family; - sockinfo.type = SOCK_STREAM; + sockinfo.os_sock = &context->accept_socket; + sockinfo.local = context->sa_server; + sockinfo.remote = context->sa_client; + sockinfo.family = context->sa_server->sa_family; + sockinfo.type = SOCK_STREAM; + sockinfo.protocol = IPPROTO_TCP; /* Restore the state corresponding to apr_os_sock_make's default * assumption of timeout -1 (really, a flaw of os_sock_make and * os_sock_put that it does not query to determine ->timeout).