]> git.mxchange.org Git - flightgear.git/commitdiff
MultiPlayer updates for MSVC from Frederic Bouvier
authorehofman <ehofman>
Sun, 23 Mar 2003 10:08:47 +0000 (10:08 +0000)
committerehofman <ehofman>
Sun, 23 Mar 2003 10:08:47 +0000 (10:08 +0000)
src/MultiPlayer/mpplayer.cxx
src/MultiPlayer/multiplayrxmgr.cxx
src/MultiPlayer/multiplaytxmgr.cxx
src/Network/multiplay.cxx

index 40ba5c5f98492a7401145321047bdff518314d09..cc6411f54e51527248568d14657c168608c26252 100644 (file)
 #include "mpplayer.hxx"
 
 #include <stdlib.h>
-#include <netdb.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
+#ifndef _MSC_VER
+# include <netdb.h>
+# include <sys/socket.h>
+# include <netinet/in.h>
+# include <arpa/inet.h>
+#endif
 #include <plib/netSocket.h>
 
 #include <Main/globals.hxx>
@@ -281,7 +283,7 @@ void MPPlayer::FillMsgHdr(T_MsgHdr *MsgHdr, const int iMsgId) {
             break;
     }
 
-    inet_aton(m_PlayerAddress.getHost(), &address);
+    address.s_addr = inet_addr( m_PlayerAddress.getHost() );
     MsgHdr->lReplyAddress = address.s_addr;
 
     MsgHdr->iReplyPort = m_PlayerAddress.getPort();
index 61ca69514c5da91c911deed778b52d6030d028e1..89b6e832cda6ecae36694b5d12a3721ee0ceb76d 100644 (file)
 ******************************************************************/
 
 #include <sys/types.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
+#ifndef _MSC_VER
+# include <sys/socket.h>
+# include <netinet/in.h>
+# include <arpa/inet.h>
+#endif
 #include <plib/netSocket.h>
 #include <stdlib.h>
 
index 0b4336b7864c937d2211ae6f903e3da691d30863..0955e29cdf5762fdfe145265b8303977ac039650 100644 (file)
 ******************************************************************/
 
 #include <sys/types.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
+#ifndef _MSC_VER
+# include <sys/socket.h>
+# include <netinet/in.h>
+# include <arpa/inet.h>
+#endif
 #include <plib/netSocket.h>
 #include <stdlib.h>
 
index b32d92297cd0dabf70e34ce1663d3ebe2f39d4e1..dfb6b6a15e7869028508bcc6f36855ea43d4955a 100644 (file)
@@ -25,7 +25,7 @@
 
 #include STL_STRING
 
-#include <iostream.h>
+#include <iostream>
 
 #include <simgear/debug/logstream.hxx>