mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 00:32:25 -04:00
nfssvc: Zero the buffer copied out when NFSSVC_DUMPMNTOPTS is set
Reported by: KMSAN MFC after: 1 week Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
2e5f615295
commit
7a9bc8a82e
1 changed files with 2 additions and 1 deletions
|
|
@ -1312,7 +1312,8 @@ nfssvc_nfscl(struct thread *td, struct nfssvc_args *uap)
|
|||
error = EINVAL;
|
||||
}
|
||||
if (error == 0) {
|
||||
buf = malloc(dumpmntopts.ndmnt_blen, M_TEMP, M_WAITOK);
|
||||
buf = malloc(dumpmntopts.ndmnt_blen, M_TEMP, M_WAITOK |
|
||||
M_ZERO);
|
||||
nfscl_retopts(VFSTONFS(nd.ni_vp->v_mount), buf,
|
||||
dumpmntopts.ndmnt_blen);
|
||||
vput(nd.ni_vp);
|
||||
|
|
|
|||
Loading…
Reference in a new issue