diff options
Diffstat (limited to 'sysdeps/generic/pt-attr-setstacksize.c')
-rw-r--r-- | sysdeps/generic/pt-attr-setstacksize.c | 19 |
1 files changed, 7 insertions, 12 deletions
diff --git a/sysdeps/generic/pt-attr-setstacksize.c b/sysdeps/generic/pt-attr-setstacksize.c index d0e5102..c88f917 100644 --- a/sysdeps/generic/pt-attr-setstacksize.c +++ b/sysdeps/generic/pt-attr-setstacksize.c @@ -24,18 +24,13 @@ int pthread_attr_setstacksize (pthread_attr_t *attr, size_t stacksize) { - if (stacksize == __pthread_default_attr.stacksize) - { - attr->stacksize = stacksize; + attr->stacksize = stacksize; - /* The guard size cannot be larger than the stack itself, as - such, if the new stack size is smaller than the guard size, - we squash the guard size. */ - if (attr->guardsize > attr->stacksize) - attr->guardsize = attr->stacksize; + /* The guard size cannot be larger than the stack itself, as + such, if the new stack size is smaller than the guard size, + we squash the guard size. */ + if (attr->guardsize > attr->stacksize) + attr->guardsize = attr->stacksize; - return 0; - } - - return ENOTSUP; + return 0; } |