Added a function prototype and description on how the userland waitpid()
functionality could be supported. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@8790 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
77a6c2446a
commit
05835518ae
@ -1,8 +1,8 @@
|
||||
/* Team functions */
|
||||
|
||||
/*
|
||||
** Copyright 2002-2004, The OpenBeOS Team. All rights reserved.
|
||||
** Distributed under the terms of the OpenBeOS License.
|
||||
** Copyright 2002-2004, The Haiku Team. All rights reserved.
|
||||
** Distributed under the terms of the Haiku License.
|
||||
**
|
||||
** Copyright 2001-2002, Travis Geiselbrecht. All rights reserved.
|
||||
** Distributed under the terms of the NewOS License.
|
||||
@ -702,6 +702,31 @@ err1:
|
||||
// public team API
|
||||
|
||||
|
||||
/** This is the kernel backend for waitpid(). It is a bit more powerful when it comes
|
||||
* to the reason why a thread has died than waitpid() can be.
|
||||
*/
|
||||
|
||||
#if 0
|
||||
team_id
|
||||
wait_for_child(thread_id child, uint32 flags, thread_id *_deadChild, int32 *_reason, status_t *_returnCode)
|
||||
{
|
||||
// ToDo: implement me! We need to store the death of children in the team structure!
|
||||
|
||||
if (child > 0) {
|
||||
// wait for the specified child
|
||||
} else if (child == -1) {
|
||||
// wait for any children of this team to die
|
||||
} else if (child == 0) {
|
||||
// wait for any children of this process group to die
|
||||
} else {
|
||||
// wait for any children with progress group of the absolute value of "child"
|
||||
}
|
||||
|
||||
return B_ERROR;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
status_t
|
||||
wait_for_team(team_id id, status_t *_returnCode)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user