2 #include "pthread_impl.h"
5 int pthread_setattr_default_np(const pthread_attr_t *attrp)
7 /* Reject anything in the attr object other than stack/guard size. */
8 pthread_attr_t tmp = *attrp, zero = { 0 };
11 if (memcmp(&tmp, &zero, sizeof tmp))
15 if (attrp->_a_stacksize >= __default_stacksize)
16 __default_stacksize = attrp->_a_stacksize;
17 if (attrp->_a_guardsize >= __default_guardsize)
18 __default_guardsize = attrp->_a_guardsize;
24 int pthread_getattr_default_np(pthread_attr_t *attrp)
27 *attrp = (pthread_attr_t) {
28 ._a_stacksize = __default_stacksize,
29 ._a_guardsize = __default_guardsize,