From 5df4be11657fc49d74e1e6b39c0003f7cf2f3772 Mon Sep 17 00:00:00 2001 From: Yang Tse Date: Wed, 18 Oct 2006 21:05:40 +0000 Subject: Check for USE_WINSOCK instead of WIN32 where the check was done to verify winsock API availability. --- tests/server/util.h | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'tests/server/util.h') diff --git a/tests/server/util.h b/tests/server/util.h index acda12159..17d82f156 100644 --- a/tests/server/util.h +++ b/tests/server/util.h @@ -23,7 +23,7 @@ * $Id$ ***************************************************************************/ -int ourerrno(void); +int our_sockerrno(void); void logmsg(const char *msg, ...); #ifndef FALSE @@ -44,19 +44,21 @@ extern const char *path; #define sleep(sec) Sleep ((sec)*1000) +#undef perror +#define perror(m) win32_perror(m) +void win32_perror (const char *msg); +#endif /* WIN32 */ + +#ifdef USE_WINSOCK #define EINPROGRESS WSAEINPROGRESS #define EWOULDBLOCK WSAEWOULDBLOCK #define EISCONN WSAEISCONN #define ENOTSOCK WSAENOTSOCK #define ECONNREFUSED WSAECONNREFUSED -#undef perror -#define perror(m) win32_perror(m) -void win32_perror (const char *msg); - void win32_init(void); void win32_cleanup(void); -#endif /* WIN32 */ +#endif /* USE_WINSOCK */ /* returns the path name to the test case file */ char *test2file(long testno); -- cgit v1.2.3