mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-03-21 15:41:09 +08:00
re PR libobjc/19850 (libobjc leaks threads on posix)
PR libobjc/19850 * gthr-posix.h (__gthread_objc_thread_detach): Use _objc_thread_attribs when detaching a thread. * gthr-posix95.h (__gthread_objc_thread_detach): Same change. From-SVN: r163923
This commit is contained in:
parent
6fa0abcfd9
commit
708e07fbd3
@ -1,3 +1,10 @@
|
||||
2010-09-06 Nicola Pero <nicola.pero@meta-innovation.com>
|
||||
|
||||
PR libobjc/19850
|
||||
* gthr-posix.h (__gthread_objc_thread_detach): Use
|
||||
_objc_thread_attribs when detaching a thread.
|
||||
* gthr-posix95.h (__gthread_objc_thread_detach): Same change.
|
||||
|
||||
2010-09-06 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR target/45524
|
||||
|
@ -370,7 +370,8 @@ __gthread_objc_thread_detach (void (*func)(void *), void *arg)
|
||||
if (!__gthread_active_p ())
|
||||
return NULL;
|
||||
|
||||
if (!(__gthrw_(pthread_create) (&new_thread_handle, NULL, (void *) func, arg)))
|
||||
if (!(__gthrw_(pthread_create) (&new_thread_handle, &_objc_thread_attribs,
|
||||
(void *) func, arg)))
|
||||
thread_id = (objc_thread_t) new_thread_handle;
|
||||
else
|
||||
thread_id = NULL;
|
||||
|
@ -294,7 +294,8 @@ __gthread_objc_thread_detach (void (*func)(void *), void *arg)
|
||||
if (!__gthread_active_p ())
|
||||
return NULL;
|
||||
|
||||
if (!(__gthrw_(pthread_create) (&new_thread_handle, NULL, (void *) func, arg)))
|
||||
if (!(__gthrw_(pthread_create) (&new_thread_handle, &_objc_thread_attribs,
|
||||
(void *) func, arg)))
|
||||
thread_id = (objc_thread_t) new_thread_handle;
|
||||
else
|
||||
thread_id = NULL;
|
||||
|
Loading…
x
Reference in New Issue
Block a user