https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=293253
Bug ID: 293253
Summary: Possible skipping of one entry when gathering gstat(8)
data
Product: Base System
Version: CURRENT
Hardware: Any
OS: Any
Status: New
Severity: Affects Only Me
Priority: ---
Component: bin
Assignee: [email protected]
Reporter: [email protected]
Unfortunately I don't know how to easily test this (and I didn't tested this),
but lib/libgeom/geom_stats.c/geom_stats_snapshot_next() looks like skipping
latest entry of devstat array. It checks if the array is ended and returns NULL
if so, but the 'gsp' points to just fetched latest entry of it, which is lost.
Looked briefly at sys/kern/subr_devstat.c/devstat_alloc(), I didn't found any
special handling of that last entry, so it seems it could be used.
This may lead to last entry become invisible to gstat(8).
--
You are receiving this mail because:
You are the assignee for the bug.