git: dc7526170d4c - main - posixshm: Report output buffer truncation from kern.ipc.posix_shm_list
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 17 Jan 2022 13:35:43 UTC
The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=dc7526170d4cc62f35bafb25dd026399c612ed5b commit dc7526170d4cc62f35bafb25dd026399c612ed5b Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2022-01-17 13:33:05 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2022-01-17 13:35:19 +0000 posixshm: Report output buffer truncation from kern.ipc.posix_shm_list PR: 240573 Reviewed by: kib MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D33912 --- sys/kern/uipc_shm.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/sys/kern/uipc_shm.c b/sys/kern/uipc_shm.c index 6fb083498e18..04c2c65af02e 100644 --- a/sys/kern/uipc_shm.c +++ b/sys/kern/uipc_shm.c @@ -2052,9 +2052,6 @@ sysctl_posix_shm_list(SYSCTL_HANDLER_ARGS) if (error != 0) break; pack_kinfo(&kif); - if (req->oldptr != NULL && - kif.kf_structsize + curlen > req->oldlen) - break; error = sbuf_bcat(&sb, &kif, kif.kf_structsize) == 0 ? 0 : ENOMEM; if (error != 0)