summaryrefslogtreecommitdiff
path: root/pthread
diff options
context:
space:
mode:
Diffstat (limited to 'pthread')
-rw-r--r--pthread/pt-create.c14
-rw-r--r--pthread/pt-exit.c4
-rw-r--r--pthread/pt-getattr.c8
3 files changed, 13 insertions, 13 deletions
diff --git a/pthread/pt-create.c b/pthread/pt-create.c
index 112ed46..d88afae 100644
--- a/pthread/pt-create.c
+++ b/pthread/pt-create.c
@@ -103,7 +103,7 @@ __pthread_create_internal (struct __pthread **thread,
/* Use the default attributes if ATTR is NULL. */
setup = attr ? attr : &__pthread_default_attr;
- stacksize = setup->stacksize;
+ stacksize = setup->__stacksize;
if (!stacksize)
{
struct rlimit rlim;
@@ -115,12 +115,12 @@ __pthread_create_internal (struct __pthread **thread,
}
/* Initialize the thread state. */
- pthread->state = (setup->detachstate == PTHREAD_CREATE_DETACHED
+ pthread->state = (setup->__detachstate == PTHREAD_CREATE_DETACHED
? PTHREAD_DETACHED : PTHREAD_JOINABLE);
- if (setup->stackaddr)
+ if (setup->__stackaddr)
{
- pthread->stackaddr = setup->stackaddr;
+ pthread->stackaddr = setup->__stackaddr;
/* If the user supplied a stack, it is not our responsibility to
setup a stack guard. */
@@ -131,13 +131,13 @@ __pthread_create_internal (struct __pthread **thread,
{
/* Allocate a stack. */
err = __pthread_stack_alloc (&pthread->stackaddr,
- ((setup->guardsize + __vm_page_size-1)
+ ((setup->__guardsize + __vm_page_size-1)
/ __vm_page_size) * __vm_page_size
+ stacksize);
if (err)
goto failed_stack_alloc;
- pthread->guardsize = setup->guardsize;
+ pthread->guardsize = setup->__guardsize;
pthread->stack = 1;
}
@@ -244,7 +244,7 @@ __pthread_create_internal (struct __pthread **thread,
failed_thread_alloc:
if (pthread->stack)
__pthread_stack_dealloc (pthread->stackaddr,
- ((setup->guardsize + __vm_page_size-1)
+ ((setup->__guardsize + __vm_page_size-1)
/ __vm_page_size) * __vm_page_size
+ stacksize);
failed_stack_alloc:
diff --git a/pthread/pt-exit.c b/pthread/pt-exit.c
index 6d827db..3427de5 100644
--- a/pthread/pt-exit.c
+++ b/pthread/pt-exit.c
@@ -43,8 +43,8 @@ __pthread_exit (void *status)
for (handlers = __pthread_get_cleanup_stack ();
*handlers;
- *handlers = (*handlers)->next)
- (*handlers)->handler ((*handlers)->arg);
+ *handlers = (*handlers)->__next)
+ (*handlers)->__handler ((*handlers)->__arg);
pthread_setcancelstate (oldstate, &oldstate);
diff --git a/pthread/pt-getattr.c b/pthread/pt-getattr.c
index edb013f..574420a 100644
--- a/pthread/pt-getattr.c
+++ b/pthread/pt-getattr.c
@@ -39,12 +39,12 @@ pthread_getattr_np (pthread_t thread, pthread_attr_t *attr)
are not supported yet, so fill them with our default values. */
*attr = __pthread_default_attr;
- attr->stackaddr = pthread->stackaddr +
+ attr->__stackaddr = pthread->stackaddr +
((pthread->guardsize + __vm_page_size-1)
/ __vm_page_size * __vm_page_size);
- attr->stacksize = pthread->stacksize;
- attr->guardsize = pthread->guardsize;
- attr->detachstate = (pthread->state == PTHREAD_DETACHED
+ attr->__stacksize = pthread->stacksize;
+ attr->__guardsize = pthread->guardsize;
+ attr->__detachstate = (pthread->state == PTHREAD_DETACHED
? PTHREAD_CREATE_DETACHED : PTHREAD_CREATE_JOINABLE);
return 0;