diff options
author | Yang Tse <yangsita@gmail.com> | 2006-10-11 16:01:16 +0000 |
---|---|---|
committer | Yang Tse <yangsita@gmail.com> | 2006-10-11 16:01:16 +0000 |
commit | e150150d9f1e0578c85af05de15ab6336066cec1 (patch) | |
tree | 7ccad4887ea68afc2ce0503b4fa7a913fdd40d60 /tests/server | |
parent | 943f0733bb187dfacdfdc23806ab030cee97c9fc (diff) |
Remove redundant __CYGWIN__ symbol check
Diffstat (limited to 'tests/server')
-rw-r--r-- | tests/server/resolve.c | 2 | ||||
-rw-r--r-- | tests/server/sockfilt.c | 2 | ||||
-rw-r--r-- | tests/server/sws.c | 2 | ||||
-rw-r--r-- | tests/server/tftpd.c | 2 | ||||
-rw-r--r-- | tests/server/util.c | 6 | ||||
-rw-r--r-- | tests/server/util.h | 5 |
6 files changed, 9 insertions, 10 deletions
diff --git a/tests/server/resolve.c b/tests/server/resolve.c index 98a3f4e08..b579d460e 100644 --- a/tests/server/resolve.c +++ b/tests/server/resolve.c @@ -112,7 +112,7 @@ int main(int argc, char *argv[]) return 0; } -#if defined(WIN32) && !defined(__CYGWIN__) +#ifdef WIN32 win32_init(); atexit(win32_cleanup); #endif diff --git a/tests/server/sockfilt.c b/tests/server/sockfilt.c index 165ecf27a..bf60a2c64 100644 --- a/tests/server/sockfilt.c +++ b/tests/server/sockfilt.c @@ -552,7 +552,7 @@ int main(int argc, char *argv[]) } } -#if defined(WIN32) && !defined(__CYGWIN__) +#ifdef WIN32 win32_init(); atexit(win32_cleanup); #else diff --git a/tests/server/sws.c b/tests/server/sws.c index c2c681dfe..7f9091f4a 100644 --- a/tests/server/sws.c +++ b/tests/server/sws.c @@ -773,7 +773,7 @@ int main(int argc, char *argv[]) } } -#if defined(WIN32) && !defined(__CYGWIN__) +#ifdef WIN32 win32_init(); atexit(win32_cleanup); #else diff --git a/tests/server/tftpd.c b/tests/server/tftpd.c index 5c3caf4f8..c234dbf19 100644 --- a/tests/server/tftpd.c +++ b/tests/server/tftpd.c @@ -458,7 +458,7 @@ int main(int argc, char **argv) } } -#if defined(WIN32) && !defined(__CYGWIN__) +#ifdef WIN32 win32_init(); atexit(win32_cleanup); #endif diff --git a/tests/server/util.c b/tests/server/util.c index 724cb8517..7bf8bdc82 100644 --- a/tests/server/util.c +++ b/tests/server/util.c @@ -65,7 +65,7 @@ const struct in6_addr in6addr_any = {{ IN6ADDR_ANY_INIT }}; */ int ourerrno(void) { -#if defined(WIN32) && !defined(__CYGWIN__) +#ifdef WIN32 return (int)GetLastError(); #else return errno; @@ -101,7 +101,7 @@ void logmsg(const char *msg, ...) } } -#if defined(REAL_WIN32) +#ifdef WIN32 /* use instead of perror() on generic windows */ void win32_perror (const char *msg) { @@ -145,7 +145,7 @@ void win32_cleanup(void) { WSACleanup(); } -#endif /* REAL_WIN32 */ +#endif /* WIN32 */ /* set by the main code to point to where the test dir is */ const char *path="."; diff --git a/tests/server/util.h b/tests/server/util.h index 30395fc4c..acda12159 100644 --- a/tests/server/util.h +++ b/tests/server/util.h @@ -38,10 +38,9 @@ void logmsg(const char *msg, ...); /* global variable, where to find the 'data' dir */ extern const char *path; -#if defined(WIN32) && !defined(__CYGWIN__) +#ifdef WIN32 #include <process.h> #include <fcntl.h> -#define REAL_WIN32 #define sleep(sec) Sleep ((sec)*1000) @@ -57,7 +56,7 @@ void win32_perror (const char *msg); void win32_init(void); void win32_cleanup(void); -#endif /* WIN32 && !__CYGWIN__ */ +#endif /* WIN32 */ /* returns the path name to the test case file */ char *test2file(long testno); |