|
From: Hans D. <dul...@us...> - 2001-03-25 14:04:27
|
Update of /cvsroot/corelinux/corelinux/src/classlibs/corelinux
In directory usw-pr-cvs1:/tmp/cvs-serv21478
Modified Files:
Thread.cpp
Log Message:
Reactivated sigaction, added code in threadTerminated to destroy
terminating context.
Index: Thread.cpp
===================================================================
RCS file: /cvsroot/corelinux/corelinux/src/classlibs/corelinux/Thread.cpp,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -r1.18 -r1.19
*** Thread.cpp 2001/03/20 04:09:11 1.18
--- Thread.cpp 2001/03/25 14:04:23 1.19
***************
*** 75,79 ****
//
- /*
struct sigaction sa;
memset(&sa,0,sizeof(sa));
--- 75,78 ----
***************
*** 82,86 ****
sigaction(SIGCHLD,&sa,NULLPTR);
- */
}
else
--- 81,84 ----
***************
*** 382,386 ****
Int aStatus(0);
waitpid(anId.getScalar(),&aStatus,0);
! return aContext.getReturnCode();
}
--- 380,384 ----
Int aStatus(0);
waitpid(anId.getScalar(),&aStatus,0);
! return aStatus;
}
***************
*** 474,477 ****
--- 472,479 ----
std::cout << " Terminate received " << std::endl;
*/
+ ThreadIdentifier anId = DwordPtr(vPtr)[13];
+ ThreadContext aContext(Thread::getThreadContext(anId));
+ aContext.setThreadState (THREAD_NORMAL_EXIT);
+ destroyThreadContext (anId);
}
|