mirror of
https://github.com/zeromq/libzmq.git
synced 2025-10-30 13:47:13 +01:00
Problem: kFreeBSD does not implement pthread_setschedparam
Solution: do not fail on kFreeBSD if this feature is not available at runtime. Thanks Steven Chamberlain <steven@pyro.eu.org> for the patch!
This commit is contained in:
@@ -145,6 +145,12 @@ void zmq::thread_t::setSchedulingParameters(int priority_, int schedulingPolicy_
|
||||
#endif
|
||||
|
||||
rc = pthread_setschedparam(descriptor, policy, ¶m);
|
||||
|
||||
#ifdef __FreeBSD_kernel__
|
||||
// If this feature is unavailable at run-time, don't abort.
|
||||
if(rc == ENOSYS) return;
|
||||
#endif
|
||||
|
||||
posix_assert (rc);
|
||||
#else
|
||||
|
||||
|
||||
Reference in New Issue
Block a user