]> git.mxchange.org Git - simgear.git/blobdiff - simgear/io/sg_socket.cxx
Linux test_HTTP fixes.
[simgear.git] / simgear / io / sg_socket.cxx
index 770bb51dcbbbf274e84e996bc3fb12a1e04a6315..4ca13150170e6bfba5eb052c8115ce6e85b1f668 100644 (file)
@@ -36,6 +36,7 @@
 #include "sg_socket.hxx"
 
 bool SGSocket::init = false;
+using std::string;
 
 SGSocket::SGSocket( const string& host, const string& port_, 
                    const string& style ) :
@@ -84,7 +85,7 @@ SGSocket::make_server_socket()
        return false;
     }
 
-    if (sock.bind( "", port ) < 0)
+    if (sock.bind( hostname.c_str(), port ) < 0)
     {
        SG_LOG( SG_IO, SG_ALERT,
                "Error: bind() failed in make_server_socket()" );