]> granicus.if.org Git - apache/commitdiff
Get the correct IP address if ServerName isn't set and we can't
authorTony Finch <fanf@apache.org>
Thu, 1 Feb 2001 09:59:25 +0000 (09:59 +0000)
committerTony Finch <fanf@apache.org>
Thu, 1 Feb 2001 09:59:25 +0000 (09:59 +0000)
find a fully-qualified domain name at startup.
PR:             7170
Submitted by:   Danek Duvall <dduvall@eng.sun.com>

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87938 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
server/util.c

diff --git a/CHANGES b/CHANGES
index 1828259fdd9c7658bf0ae6e491936f691004fcb4..05b67886e48d1c19c03d14d43f1a7a7170fe139e 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,4 +1,9 @@
 Changes with Apache 2.0b1
+
+  *) Get the correct IP address if ServerName isn't set and we can't
+     find a fully-qualified domain name at startup.
+     PR#7170 [Danek Duvall <dduvall@eng.sun.com>]
+
   *) Make mod_cgid work with SuExec.  [Ryan Bloom]
 
   *) Adopt apr user/group name features for mod_rewrite.  Eliminates some
index 3e9d7a1d3c43fb404f582e0f25cd3696ebcfaf67..9ca1eb0f22116a08e3bcbfb3ee2c00a1c4141992 100644 (file)
@@ -1798,7 +1798,7 @@ char *ap_get_local_host(apr_pool_t *a)
         if ((!(p = gethostbyname(str))) 
             || (!(server_hostname = find_fqdn(a, p)))) {
             /* Recovery - return the default servername by IP: */
-            if (!str && p->h_addr_list[0]) {
+            if (p->h_addr_list[0]) {
                 apr_snprintf(str, sizeof(str), "%pA", p->h_addr_list[0]);
                server_hostname = apr_pstrdup(a, str);
                 /* We will drop through to report the IP-named server */