httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 40408] - Apache 2.2.3 is not starting
Date Fri, 08 Sep 2006 09:04:58 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=40408>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=40408


laxmiharikumar@yahoo.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|bugs@httpd.apache.org       |jorton@redhat.com
             Status|NEEDINFO                    |NEW




------- Additional Comments From laxmiharikumar@yahoo.com  2006-09-08 09:04 -------
This problem is Tru64 specific. Here the make_sock function is being called
twice with IP address 0.0.0.0 and the second bind obviously fails.

In alloc_listener function of listen.c, the comparison:

264 if (port == oldport &&
265 ((!addr && !sa->hostname) ||
266                   ((addr && sa->hostname) && !strcmp(sa->hostname,
addr))

is failing (when the function gets called the second time) because of which
found_listener is not set to 1 

This is failing because sa->hostname is being set to "0.0.0.0" in
apr_sockaddr_info_get (which in turn calls call_resolver() in sockaddr.c. This
function has a #ifdef OSF1 where hostname is being set as 0.0.0.0 or ::
depending on IPv4 or IPv6).

We have tried a fix on the same issue for alloc_listener(). Posting it here.

File listen.c
------------

34,38c34
< #if APR_HAVE_IPV6
< static int default_family = APR_UNSPEC;
< #else
< static int default_family = APR_INET;
< #endif
---
>
248,272d243
< static void find_default_family(apr_pool_t *p)
< {
< #if APR_HAVE_IPV6
<     if (default_family == APR_UNSPEC) {
<         apr_status_t sock_rv;
<         apr_socket_t *tmp_sock;
<         apr_sockaddr_t *sa;
<
<         if ((sock_rv = apr_socket_create(&tmp_sock, APR_INET6, SOCK_STREAM, 0,
 p))
<             == APR_SUCCESS &&
< apr_sockaddr_info_get(&sa, NULL, APR_INET6, 0, 0, p) == APR_SUCCESS
< &&
<             apr_socket_bind(tmp_sock, sa) == APR_SUCCESS) {
<             default_family = APR_INET6;
<         }
<         else {
<             default_family = APR_INET;
<         }
<         if (sock_rv == APR_SUCCESS) {
<             apr_socket_close(tmp_sock);
<         }
<     }
< #endif
< }
<
280,299d250
<
< #ifdef OSF1
<     if (!addr) { /* don't bind to specific interface */
<         find_default_family(process->pool);
<         switch(default_family) {
<         case APR_INET:
<             addr = "0.0.0.0";
<             break;
<
< #if APR_HAVE_IPV6
<         case APR_INET6:
<             addr = "::";
<             break;
< #endif
<
<         default:
<             ap_assert(1 != 1); /* should not occur */
<         }
<     }
< #endif

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


Mime
View raw message