httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s.@apache.org
Subject svn commit: r1745863 - /httpd/httpd/trunk/support/logresolve.c
Date Sat, 28 May 2016 10:45:18 GMT
Author: sf
Date: Sat May 28 10:45:18 2016
New Revision: 1745863

URL: http://svn.apache.org/viewvc?rev=1745863&view=rev
Log:
Fix segfault with logresolve -c and IPv6

Due to a logic error, there could be a NULL pointer dereference.

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=823259

Modified:
    httpd/httpd/trunk/support/logresolve.c

Modified: httpd/httpd/trunk/support/logresolve.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/support/logresolve.c?rev=1745863&r1=1745862&r2=1745863&view=diff
==============================================================================
--- httpd/httpd/trunk/support/logresolve.c (original)
+++ httpd/httpd/trunk/support/logresolve.c Sat May 28 10:45:18 2016
@@ -284,7 +284,7 @@ int main(int argc, const char * const ar
              */
             status = apr_sockaddr_info_get(&ipdouble, hostname, ip->family, 0,
                                            0, pline);
-            if (status == APR_SUCCESS ||
+            if (status != APR_SUCCESS ||
                 memcmp(ipdouble->ipaddr_ptr, ip->ipaddr_ptr, ip->ipaddr_len)) {
                 /* Double-lookup failed  */
                 *space = ' ';



Mime
View raw message