instead of just the first one reported by the resolver. This
corrects a regression since 1.3.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@103897
13f79535-47bb-0310-9956-
ffa450edef68
[Remove entries to the current 2.0 section below, when backported]
+ *) <VirtualHost myhost> now applies to all IP addresses for myhost
+ instead of just the first one reported by the resolver. This
+ corrects a regression since 1.3. [Jeff Trawick]
+
*) <IfModule> now recognizes the module identifier in addition to the
file name. PR 29003. [Edward Rudd <eddie omegaware.com>, André Malo]
}
}
- /* XXX Gotta go through *all* addresses for the host name!
- * Fix apr_sockaddr_info_get() to save them! */
-
- sar = apr_pcalloc(p, sizeof(server_addr_rec));
- **paddr = sar;
- *paddr = &sar->next;
- sar->host_addr = my_addr;
- sar->host_port = port;
- sar->virthost = host;
+ /* Remember all addresses for the host */
+
+ do {
+ sar = apr_pcalloc(p, sizeof(server_addr_rec));
+ **paddr = sar;
+ *paddr = &sar->next;
+ sar->host_addr = my_addr;
+ sar->host_port = port;
+ sar->virthost = host;
+ my_addr = my_addr->next;
+ } while (my_addr);
+
return NULL;
}