Return-Path: Delivered-To: apmail-apr-bugs-archive@www.apache.org Received: (qmail 9836 invoked from network); 3 Apr 2009 17:35:42 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 3 Apr 2009 17:35:42 -0000 Received: (qmail 13682 invoked by uid 500); 3 Apr 2009 17:35:42 -0000 Delivered-To: apmail-apr-bugs-archive@apr.apache.org Received: (qmail 13647 invoked by uid 500); 3 Apr 2009 17:35:41 -0000 Mailing-List: contact bugs-help@apr.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@apr.apache.org Delivered-To: mailing list bugs@apr.apache.org Received: (qmail 13639 invoked by uid 99); 3 Apr 2009 17:35:41 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 03 Apr 2009 17:35:41 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 03 Apr 2009 17:35:39 +0000 Received: by brutus.apache.org (Postfix, from userid 33) id D21AC234C051; Fri, 3 Apr 2009 10:35:18 -0700 (PDT) From: bugzilla@apache.org To: bugs@apr.apache.org Subject: DO NOT REPLY [Bug 46964] New: apr_sockaddr_vars_set() Needs to always set the port X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: newchanged X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: APR X-Bugzilla-Component: APR X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: Joe.Mudd@sas.com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: bugs@apr.apache.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Fri, 3 Apr 2009 10:35:18 -0700 (PDT) X-Virus-Checked: Checked by ClamAV on apache.org https://issues.apache.org/bugzilla/show_bug.cgi?id=46964 Summary: apr_sockaddr_vars_set() Needs to always set the port Product: APR Version: 1.2.12 Platform: PC OS/Version: AIX Status: NEW Severity: normal Priority: P2 Component: APR AssignedTo: bugs@apr.apache.org ReportedBy: Joe.Mudd@sas.com When running on AIX, calling: apr_sockaddr_info_get(&sa, "localhost", APR_UNSPEC, 0, APR_IPV6_ADDR_OK, pool); when the library was built w/IPv6 ok but the host only has IPV4 sometimes results in a sockaddr that has a non-zero port. In my case, 1. Which causes the subsequent apr_socket_bind() to fail w/EACCES. apr_sockaddr_info_get(), via call_resolver(), calls getaddrinfo() with a host name and a NULL service name. When successful, the copied addrinfo->ai_addr sometimes has a 1 in sin_port. Since the man page for getaddrinfo() doesn't seem to explicitly state what the returned value for the port will be when service name is NULL, perhaps the prudent thing for apr_sockaddr_vars_set() to do would be to always set the port... even when the port is zero. -- Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: bugs-unsubscribe@apr.apache.org For additional commands, e-mail: bugs-help@apr.apache.org