diff options
author | Vito Caputo <vcaputo@pengaru.com> | 2020-05-08 21:34:45 -0700 |
---|---|---|
committer | Vito Caputo <vcaputo@pengaru.com> | 2020-05-08 21:42:55 -0700 |
commit | 4f9e3f857e3e0a6d9f02e577a30f35c318388e05 (patch) | |
tree | 8b276e70941e55007b06b583d41bb9a0b4b86b85 /src/libvmon/defs/sys_vm.def | |
parent | 4c9a16f4efe7fe2af2f418f8c668e51626eaf702 (diff) |
libvmon: fix bug in proc_follow_children()
There's an optimization where the search start pointer is
advanced on matches, to resume searching from the last matched
position. The assumption is that the in-memory list order and
the order coming out of the proc file will align.
Except using the standard list iterator, this would treat the
list head @ &proc->children as just another node in the list.
In the unlikely case where &proc->children treated as a siblings
member in a vmon_proc_t actually resulted in contents lining up
as a match, the generation update would scribble over part of
the parent pointer member, making things crashy when the parent
was dereferenced later in the fuction.
This commit just makes it skip over the &proc->children node if
encountered, just like in proc_follow_threads().
Hopefully this eliminates the remaining very rare vwm crashes
that occur during big parallel builds of the kernel or systemd.
Diffstat (limited to 'src/libvmon/defs/sys_vm.def')
0 files changed, 0 insertions, 0 deletions