mirror of
https://github.com/opnsense/src.git
synced 2026-06-14 19:20:18 -04:00
vfs: Return early from sysctl_vfs_ctl() if no input was given
Otherwise we end up searching for a mountpoint using an uninitialized key, and likely failing the version test. This violates KMSAN's invariants, so simply return immediately instead. MFC after: 2 weeks
This commit is contained in:
parent
48d6b52add
commit
d8703cd802
1 changed files with 2 additions and 0 deletions
|
|
@ -6519,6 +6519,8 @@ sysctl_vfs_ctl(SYSCTL_HANDLER_ARGS)
|
|||
int error;
|
||||
struct mount *mp;
|
||||
|
||||
if (req->newptr == NULL)
|
||||
return (EINVAL);
|
||||
error = SYSCTL_IN(req, &vc, sizeof(vc));
|
||||
if (error)
|
||||
return (error);
|
||||
|
|
|
|||
Loading…
Reference in a new issue