From: Carlos O'Donell Date: Sat, 12 Jan 2013 01:52:05 +0000 (-0500) Subject: Remove unnecessary assert on attr in allocate_stack(). X-Git-Tag: glibc-2.18~829 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c0609c5c5e4b94f744ba952bb7d005bdd3684c71;p=thirdparty%2Fglibc.git Remove unnecessary assert on attr in allocate_stack(). --- diff --git a/nptl/ChangeLog b/nptl/ChangeLog index 33152e2550a..4aacc17e994 100644 --- a/nptl/ChangeLog +++ b/nptl/ChangeLog @@ -1,3 +1,8 @@ +2013-01-11 Carlos O'Donell + + * allocatestack.c (allocate_stack): Add comment. Remove assert + on attr. + 2013-01-11 H.J. Lu * Makefile (tst-cancel7-ARGS: Replace $(host-built-program-cmd) diff --git a/nptl/allocatestack.c b/nptl/allocatestack.c index d1056eefa0f..31c88291ae9 100644 --- a/nptl/allocatestack.c +++ b/nptl/allocatestack.c @@ -340,6 +340,10 @@ change_stack_perm (struct pthread *pd } +/* Returns a usable stack for a new thread either by allocating a + new stack or reusing a cached stack of sufficient size. + ATTR must be non-NULL and point to a valid pthread_attr. + PDP must be non-NULL. */ static int allocate_stack (const struct pthread_attr *attr, struct pthread **pdp, ALLOCATE_STACK_PARMS) @@ -349,7 +353,6 @@ allocate_stack (const struct pthread_attr *attr, struct pthread **pdp, size_t pagesize_m1 = __getpagesize () - 1; void *stacktop; - assert (attr != NULL); assert (powerof2 (pagesize_m1 + 1)); assert (TCB_ALIGNMENT >= STACK_ALIGN);