Commit 25253739 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Use POSIX TPS option only if present

parent 4c17a524
......@@ -779,6 +779,8 @@ int vlc_clone (vlc_thread_t *p_handle, void * (*entry) (void *), void *data,
sigaddset (&set, SIGPIPE); /* We don't want this one, really! */
pthread_sigmask (SIG_BLOCK, &set, &oldset);
}
#if (_POSIX_THREAD_PRIORITY_SCHEDULING >= 0)
{
struct sched_param sp = { .sched_priority = priority, };
int policy;
......@@ -791,6 +793,9 @@ int vlc_clone (vlc_thread_t *p_handle, void * (*entry) (void *), void *data,
pthread_attr_setschedpolicy (&attr, policy);
pthread_attr_setschedparam (&attr, &sp);
}
#else
(void) priority;
#endif
/* The thread stack size.
* The lower the value, the less address space per thread, the highest
......
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