Disabled name lookup for server hostname in favour of returning IP address. Annoying...
Ian Wells [Mon, 22 Mar 2010 11:30:38 +0000 (11:30 +0000)]
Changes
lib/Catalyst/Engine/HTTP.pm

diff --git a/Changes b/Changes
index ead2c17..4fb2dff 100644 (file)
--- a/Changes
+++ b/Changes
      in parameter filtering (for example).
    - $c->model/view/controller have become a lot faster for non-regexp names
      by using direct hash lookup instead of looping.
+   - Now reports the used server address as an IP string rather than a
+     looked up hostname (because nothing really cares and hostname
+     lookups, even on local interfaces, can be slow on dev machines with
+     hosed DNS setups)
 
   Bug fixed:
     - DispatchType::Index's uri_for_action only returns for actions registered
index 7f01795..6b0bc12 100644 (file)
@@ -534,8 +534,7 @@ sub _socket_data {
         peeraddr  => $iaddr
             ? ( inet_ntoa($iaddr) || '127.0.0.1' )
             : '127.0.0.1',
-        localname => gethostbyaddr( $localiaddr, AF_INET ) || 'localhost',
-        localaddr => inet_ntoa($localiaddr) || '127.0.0.1',
+        localname => inet_ntoa($localiaddr) || '127.0.0.1',
     };
 
     return $data;