Convert to new server name API
authorscantor <scantor@cb58f699-b61c-0410-a6fe-9272a202ed29>
Tue, 27 Mar 2012 17:54:08 +0000 (17:54 +0000)
committerscantor <scantor@cb58f699-b61c-0410-a6fe-9272a202ed29>
Tue, 27 Mar 2012 17:54:08 +0000 (17:54 +0000)
git-svn-id: https://svn.shibboleth.net/cpp-sp/branches/REL_2@3599 cb58f699-b61c-0410-a6fe-9272a202ed29

apache/mod_apache.cpp

index 357a82a..1da37e2 100644 (file)
@@ -374,7 +374,11 @@ public:
       return HTTPRequest::isSecure();
   }
   const char* getHostname() const {
-    return ap_get_server_name(m_req);
+#ifdef SHIB_APACHE_24
+      return ap_get_server_name_for_url(m_req);
+#else
+      return ap_get_server_name(m_req);
+#endif
   }
   int getPort() const {
     return ap_get_server_port(m_req);