mirror of
https://github.com/zeromq/libzmq.git
synced 2025-03-09 15:26:04 +00:00
z/OS: Skip pthread_{get,set}schedparam
Updated: src/thread.cpp: On older z/OS UNIX System Services, pthread_{get,set}schedparam is not present (searching the Internet suggests it may be present in later version than the one being used for z/OS UNIX System Services porting). Make zmq::thread_t::setSchedulingParameters() a no-op on z/OS UNIX System Services. NOTE: pthread_{get,set}schedparam appear to have been introduced by POSIX.1-2001 or IEEE 1003.1-2004 so may not be universally available, and thus more platforms may need this "no-op" treatment.
This commit is contained in:
parent
b27bafff60
commit
501666d07e
@ -104,6 +104,7 @@ void zmq::thread_t::stop ()
|
||||
|
||||
void zmq::thread_t::setSchedulingParameters(int priority_, int schedulingPolicy_)
|
||||
{
|
||||
#if !defined ZMQ_HAVE_ZOS
|
||||
int policy = 0;
|
||||
struct sched_param param;
|
||||
|
||||
@ -122,6 +123,7 @@ void zmq::thread_t::setSchedulingParameters(int priority_, int schedulingPolicy_
|
||||
|
||||
rc = pthread_setschedparam(descriptor, policy, ¶m);
|
||||
posix_assert (rc);
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user