]> git.mxchange.org Git - flightgear.git/blobdiff - src/FDM/JSBSim/input_output/FGfdmSocket.cpp
remove unused files
[flightgear.git] / src / FDM / JSBSim / input_output / FGfdmSocket.cpp
index 85cb88c4f9c25c70e7695afb2b9f458e8ca8ec96..d1edb67394876a630d64a7fd39311f8437d78143 100644 (file)
@@ -52,7 +52,7 @@ using std::string;
 
 namespace JSBSim {
 
-static const char *IdSrc = "$Id$";
+static const char *IdSrc = "$Id: FGfdmSocket.cpp,v 1.27 2010/05/13 03:07:59 jberndt Exp $";
 static const char *IdHdr = ID_FDMSOCKET;
 
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -77,7 +77,9 @@ FGfdmSocket::FGfdmSocket(const string& address, int port, int protocol)
       cout << "Could not get host net address by name..." << endl;
     }
   } else {
-    if ((host = gethostbyaddr(address.c_str(), address.size(), PF_INET)) == NULL) {
+    unsigned int ip;
+    ip = inet_addr(address.c_str());
+    if ((host = gethostbyaddr((char*)&ip, address.size(), PF_INET)) == NULL) {
       cout << "Could not get host net address by number..." << endl;
     }
   }