Skip to content

Commit 2fe66a5

Browse files
committed
Document caveats of task children
1 parent 779acc4 commit 2fe66a5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/process/task.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,11 @@ impl Task {
7979

8080
/// Thread children from `/proc/<pid>/task/<tid>/children`
8181
///
82+
/// WARNING:
83+
/// This interface is not reliable unless all the child processes are stoppped or frozen.
84+
/// If a child task exits while the file is being read, non-exiting children may be omitted.
85+
/// See the procfs(5) man page for more information.
86+
///
8287
/// This data will be unique per task.
8388
pub fn children(&self) -> ProcResult<Vec<u32>> {
8489
let mut buf = String::new();

0 commit comments

Comments
 (0)