Commit 99c52770 authored by Luca Boccassi's avatar Luca Boccassi Committed by GitHub

Merge pull request #2766 from hxw/master

add __FreeBSD__ to ifdefs
parents 44f96a36 997825bd
...@@ -149,7 +149,7 @@ zmq::stream_engine_t::~stream_engine_t () ...@@ -149,7 +149,7 @@ zmq::stream_engine_t::~stream_engine_t ()
wsa_assert (rc != SOCKET_ERROR); wsa_assert (rc != SOCKET_ERROR);
#else #else
int rc = close (s); int rc = close (s);
#ifdef __FreeBSD_kernel__ #if defined(__FreeBSD_kernel__) || defined (__FreeBSD__)
// FreeBSD may return ECONNRESET on close() under load but this is not // FreeBSD may return ECONNRESET on close() under load but this is not
// an error. // an error.
if (rc == -1 && errno == ECONNRESET) if (rc == -1 && errno == ECONNRESET)
......
...@@ -152,7 +152,7 @@ void zmq::thread_t::setSchedulingParameters(int priority_, int schedulingPolicy_ ...@@ -152,7 +152,7 @@ void zmq::thread_t::setSchedulingParameters(int priority_, int schedulingPolicy_
rc = pthread_setschedparam(descriptor, policy, &param); rc = pthread_setschedparam(descriptor, policy, &param);
#ifdef __FreeBSD_kernel__ #if defined(__FreeBSD_kernel__) || defined (__FreeBSD__)
// If this feature is unavailable at run-time, don't abort. // If this feature is unavailable at run-time, don't abort.
if(rc == ENOSYS) return; if(rc == ENOSYS) return;
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment