The Pedigree Project
0.1
|
Public Member Functions | |
WaitCleanup (List< Process * > *cleanupList, Semaphore *lock) | |
void | terminated (Process *pProcess) |
Private Attributes | |
List< Process * > * | m_List |
Semaphore * | m_Lock |
Process * | m_pTerminated |
Class intended to be used for RAII to clean up waitpid state on exit.
Definition at line 502 of file system-syscalls.cc.
|
inline |
Call this with the process that terminated most recently, which is necessary because otherwise upon exit from waitpid() we attempt to access the (deleted) Process object, which is not safe.
Definition at line 515 of file system-syscalls.cc.
References Semaphore::acquire(), List< T, nodePoolSize >::begin(), PosixSubsystem::checkAddress(), List< T, nodePoolSize >::clear(), List< T, nodePoolSize >::count(), Vector< T >::count(), Dec, List< T, nodePoolSize >::end(), ERROR, Thread::Exit, PosixSubsystem::exit(), EXPORTED_PUBLIC, FATAL, PosixSubsystem::getAbi(), User::getDefaultGroup(), Process::getExitStatus(), User::getFullName(), UserManager::getGroup(), User::getHome(), Group::getId(), User::getId(), Process::getId(), Group::getName(), Timer::getNanosecond(), Scheduler::getNumProcesses(), Process::getParent(), Scheduler::getProcess(), User::getShell(), Thread::getStatus(), Process::getThread(), Machine::getTimer(), Process::getType(), Timer::getUnixTimestamp(), UserManager::getUser(), Process::getUserId(), User::getUsername(), Process::getUserTime(), Hex, Processor::information(), UserManager::instance(), Scheduler::instance(), Subsystem::kill(), PosixSession::Leader, ProcessGroup::Leader, PosixProcess::Leader, User::login(), PosixProcess::Member, ProcessGroup::Members, PosixProcess::NoGroup, NOTICE, Oct, ProcessGroup::processGroupId, List< T, nodePoolSize >::pushBack(), Vector< T >::pushBack(), Process::reap(), Scheduler::removeProcess(), Process::setCtty(), Processor::setInterrupts(), IntervalTimer::setIntervalAndValue(), terminated(), WARNING, and Scheduler::yield().
Referenced by terminated().