From e29a001a85db7bf1eb19ccfbb4049098de0d2b50 Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Sun, 16 May 1999 16:51:28 +0000 Subject: [PATCH] Added TEB in init_thread request. --- include/server.h | 1 + scheduler/client.c | 1 + server/trace.c | 3 ++- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/include/server.h b/include/server.h index f0601ade8b8..eca3e934ee0 100644 --- a/include/server.h +++ b/include/server.h @@ -102,6 +102,7 @@ struct init_process_reply struct init_thread_request { int unix_pid; /* Unix pid of new thread */ + void* teb; /* TEB of new thread (in thread address space) */ }; struct init_thread_reply { diff --git a/scheduler/client.c b/scheduler/client.c index 0bbac9d80ee..dce8f779fb8 100644 --- a/scheduler/client.c +++ b/scheduler/client.c @@ -363,6 +363,7 @@ int CLIENT_InitThread(void) struct init_thread_reply reply; req.unix_pid = getpid(); + req.teb = &thdb->teb; CLIENT_SendRequest( REQ_INIT_THREAD, -1, 1, &req, sizeof(req) ); if (CLIENT_WaitSimpleReply( &reply, sizeof(reply), NULL )) return -1; thdb->process->server_pid = reply.pid; diff --git a/server/trace.c b/server/trace.c index dcd5aa20229..c5ce0348739 100644 --- a/server/trace.c +++ b/server/trace.c @@ -65,7 +65,8 @@ static int dump_init_process_reply( struct init_process_reply *req, int len ) static int dump_init_thread_request( struct init_thread_request *req, int len ) { - fprintf( stderr, " unix_pid=%d", req->unix_pid ); + fprintf( stderr, " unix_pid=%d,", req->unix_pid ); + fprintf( stderr, " teb=%p", req->teb ); return (int)sizeof(*req); }