@@ -22,38 +22,19 @@ #include #include -#include -#ifdef OF_HAVE_SYS_SOCKET_H -# include -#endif - #import "OFStreamSocket.h" #import "OFInitializationFailedException.h" #import "OFNotConnectedException.h" #import "OFReadFailedException.h" #import "OFSetOptionFailedException.h" #import "OFWriteFailedException.h" -#ifdef __wii__ -# define BOOL OGC_BOOL -# include -# undef BOOL -# define recv(sock, buf, len, flags) net_recv(sock, buf, len, flags) -# define send(sock, buf, len, flags) net_send(sock, buf, len, flags) -#endif - -#ifndef INVALID_SOCKET -# define INVALID_SOCKET -1 -#endif - -#ifdef _WIN32 -# define close(sock) closesocket(sock) -#endif +#import "socket_helpers.h" @implementation OFStreamSocket + (void)initialize { #ifdef _WIN32