aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-12-21 23:50:51 +0000
committerUlrich Drepper <drepper@redhat.com>1999-12-21 23:50:51 +0000
commit46fd4f671c45b70909e03160aa4568db5f6c8556 (patch)
tree2a607a8ad19dc47c6faf6c7ddcac019bcaadfbb7
parent958d68077b3fa1435c010711876a9229e5cd4192 (diff)
downloadglibc-46fd4f671c45b70909e03160aa4568db5f6c8556.tar
glibc-46fd4f671c45b70909e03160aa4568db5f6c8556.tar.gz
glibc-46fd4f671c45b70909e03160aa4568db5f6c8556.tar.bz2
glibc-46fd4f671c45b70909e03160aa4568db5f6c8556.zip
Update.
1999-12-21 Ulrich Drepper <drepper@cygnus.com> * manager.c (pthread_handle_create): Set p_pid of new thread before calling the callback function to report a new thread.
-rw-r--r--linuxthreads/ChangeLog5
-rw-r--r--linuxthreads/manager.c5
2 files changed, 10 insertions, 0 deletions
diff --git a/linuxthreads/ChangeLog b/linuxthreads/ChangeLog
index e994dcc297..adeaf4093f 100644
--- a/linuxthreads/ChangeLog
+++ b/linuxthreads/ChangeLog
@@ -1,3 +1,8 @@
+1999-12-21 Ulrich Drepper <drepper@cygnus.com>
+
+ * manager.c (pthread_handle_create): Set p_pid of new thread
+ before calling the callback function to report a new thread.
+
1999-12-20 Andreas Jaeger <aj@suse.de>
* pthread.c (pthread_initialize): Move getrlimit call after
diff --git a/linuxthreads/manager.c b/linuxthreads/manager.c
index 0cbb426c9d..9f9585d8ac 100644
--- a/linuxthreads/manager.c
+++ b/linuxthreads/manager.c
@@ -445,6 +445,11 @@ static int pthread_handle_create(pthread_t *thread, const pthread_attr_t *attr,
new_thread->p_eventbuf.eventnum = TD_CREATE;
__pthread_last_event = new_thread;
+ /* We have to set the PID here since the callback function
+ in the debug library will need it and we cannot guarantee
+ the child got scheduled before the debugger. */
+ new_thread->p_pid = pid;
+
/* Now call the function which signals the event. */
__linuxthreads_create_event ();