diff --git a/src_main/io_devices/piethernet.cpp b/src_main/io_devices/piethernet.cpp index bb93ae45..b4567662 100755 --- a/src_main/io_devices/piethernet.cpp +++ b/src_main/io_devices/piethernet.cpp @@ -729,7 +729,7 @@ int PIEthernet::readDevice(void * read_to, int max_size) { //piCoutObj << "readed error" << lerr << errorString().data() << parameters()[DisonnectOnTimeout]; #ifdef WINDOWS if ((lerr == WSAEWOULDBLOCK || lerr == WSAETIMEDOUT) && !parameters()[DisonnectOnTimeout]) { -#elif ANDROID +#elif defined(ANDROID) if ((lerr == EWOULDBLOCK || lerr == EAGAIN || lerr == EINTR) && !parameters()[DisonnectOnTimeout]) { #else if ((lerr == EWOULDBLOCK || lerr == EAGAIN) && !parameters()[DisonnectOnTimeout]) { @@ -886,7 +886,7 @@ void PIEthernet::server_func(void * eth) { int lerr = ethErrorCore(); #ifdef WINDOWS if (lerr == WSAETIMEDOUT) { -#elif ANDROID +#elif defined(ANDROID) if ((lerr == EAGAIN || lerr == EINTR)) { #else if (lerr == EAGAIN) {