diff options
author | Max Kellermann <max@musicpd.org> | 2017-12-12 10:22:20 +0100 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2017-12-12 10:22:20 +0100 |
commit | dfaf08743cade4c10c464bfbbb15d8f96c6e5cd9 (patch) | |
tree | 09be190640403b134b8967e1daf0d72445b146ed /src/event | |
parent | d9552d8a6d2fbc916e5a7bf6e75c2d3b4f29c38e (diff) |
*: check defined(_WIN32) instead of defined(WIN32)
Only _WIN32 is defined by the compiler, and WIN32 is not standardized
and may be missing.
Closes #169
Diffstat (limited to 'src/event')
-rw-r--r-- | src/event/MultiSocketMonitor.cxx | 4 | ||||
-rw-r--r-- | src/event/MultiSocketMonitor.hxx | 6 | ||||
-rw-r--r-- | src/event/ServerSocket.cxx | 2 | ||||
-rw-r--r-- | src/event/SignalMonitor.cxx | 2 | ||||
-rw-r--r-- | src/event/SignalMonitor.hxx | 2 | ||||
-rw-r--r-- | src/event/SocketMonitor.cxx | 2 | ||||
-rw-r--r-- | src/event/SocketMonitor.hxx | 2 |
7 files changed, 10 insertions, 10 deletions
diff --git a/src/event/MultiSocketMonitor.cxx b/src/event/MultiSocketMonitor.cxx index 02a51e96f..907251f63 100644 --- a/src/event/MultiSocketMonitor.cxx +++ b/src/event/MultiSocketMonitor.cxx @@ -23,7 +23,7 @@ #include <algorithm> -#ifndef WIN32 +#ifndef _WIN32 #include <poll.h> #endif @@ -50,7 +50,7 @@ MultiSocketMonitor::ClearSocketList() fds.clear(); } -#ifndef WIN32 +#ifndef _WIN32 void MultiSocketMonitor::ReplaceSocketList(pollfd *pfds, unsigned n) diff --git a/src/event/MultiSocketMonitor.hxx b/src/event/MultiSocketMonitor.hxx index db6bec3cb..3b4877ee9 100644 --- a/src/event/MultiSocketMonitor.hxx +++ b/src/event/MultiSocketMonitor.hxx @@ -31,7 +31,7 @@ #include <assert.h> -#ifdef WIN32 +#ifdef _WIN32 /* ERROR is a WIN32 macro that poisons our namespace; this is a kludge to allow us to use it anyway */ #ifdef ERROR @@ -39,7 +39,7 @@ #endif #endif -#ifndef WIN32 +#ifndef _WIN32 struct pollfd; #endif @@ -189,7 +189,7 @@ public: } } -#ifndef WIN32 +#ifndef _WIN32 /** * Replace the socket list with the given file descriptors. * The given pollfd array will be modified by this method. diff --git a/src/event/ServerSocket.cxx b/src/event/ServerSocket.cxx index 556648cc4..0e2a61d4c 100644 --- a/src/event/ServerSocket.cxx +++ b/src/event/ServerSocket.cxx @@ -43,7 +43,7 @@ #include <unistd.h> #include <assert.h> -#ifdef WIN32 +#ifdef _WIN32 #include <ws2tcpip.h> #include <winsock.h> #else diff --git a/src/event/SignalMonitor.cxx b/src/event/SignalMonitor.cxx index 2fd101c86..992acf248 100644 --- a/src/event/SignalMonitor.cxx +++ b/src/event/SignalMonitor.cxx @@ -20,7 +20,7 @@ #include "config.h" #include "SignalMonitor.hxx" -#ifndef WIN32 +#ifndef _WIN32 #include "SocketMonitor.hxx" #include "util/Manual.hxx" diff --git a/src/event/SignalMonitor.hxx b/src/event/SignalMonitor.hxx index 854a565ec..cdec98945 100644 --- a/src/event/SignalMonitor.hxx +++ b/src/event/SignalMonitor.hxx @@ -24,7 +24,7 @@ class EventLoop; -#ifndef WIN32 +#ifndef _WIN32 #include "util/BindMethod.hxx" diff --git a/src/event/SocketMonitor.cxx b/src/event/SocketMonitor.cxx index a1daa07cc..8005d9c3b 100644 --- a/src/event/SocketMonitor.cxx +++ b/src/event/SocketMonitor.cxx @@ -24,7 +24,7 @@ #include <assert.h> -#ifdef WIN32 +#ifdef _WIN32 #include <winsock2.h> #else #include <sys/socket.h> diff --git a/src/event/SocketMonitor.hxx b/src/event/SocketMonitor.hxx index 989da2cfe..bac3092ce 100644 --- a/src/event/SocketMonitor.hxx +++ b/src/event/SocketMonitor.hxx @@ -28,7 +28,7 @@ #include <assert.h> #include <stddef.h> -#ifdef WIN32 +#ifdef _WIN32 /* ERROR is a WIN32 macro that poisons our namespace; this is a kludge to allow us to use it anyway */ #ifdef ERROR |