X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=src%2Fthread%2Fpthread_attr_setscope.c;h=46b520c0412c99a22d5e608ff4074a35301f4122;hb=121e3a38a1d0b324696fc1671029e4b815ea7fa4;hp=d56ee391a1dd77aad23c83805856d3018af957ec;hpb=63b06c0e904fbdbc87b3e17d067b62afe9bb3dd1;p=musl diff --git a/src/thread/pthread_attr_setscope.c b/src/thread/pthread_attr_setscope.c index d56ee391..46b520c0 100644 --- a/src/thread/pthread_attr_setscope.c +++ b/src/thread/pthread_attr_setscope.c @@ -2,6 +2,12 @@ int pthread_attr_setscope(pthread_attr_t *a, int scope) { - if (scope > 1U) return EINVAL; - return 0; + switch (scope) { + case PTHREAD_SCOPE_SYSTEM: + return 0; + case PTHREAD_SCOPE_PROCESS: + return ENOTSUP; + default: + return EINVAL; + } }