From 411cdf39fc2b961a970a0ae91b9059614251247e Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Tue, 28 Aug 2012 17:42:54 +0000 Subject: Loads of win32 compilation issues fixed. Most are fairly minor unsigned/signed mismatches because of socket handles, but there were also some order-of-definition issues that were fixed in the FD_SETSIZE definition code. Fixed a few things that just never worked on windows, like Bu::Thread::yield(). --- src/stable/tcpsocket.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/stable/tcpsocket.cpp') diff --git a/src/stable/tcpsocket.cpp b/src/stable/tcpsocket.cpp index 7ea6ca1..fa79a36 100644 --- a/src/stable/tcpsocket.cpp +++ b/src/stable/tcpsocket.cpp @@ -55,7 +55,11 @@ Bu::TcpSocket::TcpSocket( const Bu::String &sAddr, int nPort, int nTimeout, /* Create the socket. */ nTcpSocket = bu_socket( PF_INET, SOCK_STREAM, 0 ); +#ifdef WIN32 + if( nTcpSocket == INVALID_SOCKET ) +#else if( nTcpSocket < 0 ) +#endif { throw ExceptionBase("Couldn't create socket.\n"); } -- cgit v1.2.3