git: 11205b085411 - main - remote coredump: fully initialize coredump_vnode_ctx and coredump_writer structs
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 20 Sep 2025 04:18:46 UTC
The branch main has been updated by kib:
URL: https://cgit.FreeBSD.org/src/commit/?id=11205b0854113eae68f725287b8501951d67be0f
commit 11205b0854113eae68f725287b8501951d67be0f
Author: Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2025-09-19 15:38:07 +0000
Commit: Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2025-09-20 04:17:18 +0000
remote coredump: fully initialize coredump_vnode_ctx and coredump_writer structs
Reported and tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
---
sys/kern/kern_sig.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c
index da0efac0598d..8efc0886988b 100644
--- a/sys/kern/kern_sig.c
+++ b/sys/kern/kern_sig.c
@@ -2656,9 +2656,11 @@ ptrace_coredumpreq(struct thread *td, struct proc *p,
return;
}
+ memset(&wctx, 0, sizeof(wctx));
wctx.vp = tcq->tc_vp;
wctx.fcred = NOCRED;
+ memset(&cdw, 0, sizeof(wctx));
cdw.ctx = &wctx;
cdw.write_fn = core_vn_write;
cdw.extend_fn = core_vn_extend;