Date: Mon, 17 Jun 2019 11:31:27 +0000 From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 238661] mpt: print req->index rather than the pointer itself in mpt.c Message-ID: <bug-238661-227@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=238661 Bug ID: 238661 Summary: mpt: print req->index rather than the pointer itself in mpt.c Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: huangfq.daxian@gmail.com Created attachment 205179 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=205179&action=edit The patch file Print req->index instead of printing the pointer itself to avoid kernel pointer leakage. Signed-off-by: Fuqian Huang <huangfq.daxian@gmail.com> --- sys/dev/mpt/mpt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/mpt/mpt.c b/sys/dev/mpt/mpt.c index 6e41ff079e9..6ea00fc8bb1 100644 --- a/sys/dev/mpt/mpt.c +++ b/sys/dev/mpt/mpt.c @@ -488,8 +488,8 @@ mpt_default_reply_handler(struct mpt_softc *mpt, request_t *req, { mpt_prt(mpt, - "Default Handler Called: req=%p:%u reply_descriptor=%x frame=%p\n", - req, req->serno, reply_desc, reply_frame); + "Default Handler Called: req=%u:%u reply_descriptor=%x frame=%p\n", + req->index, req->serno, reply_desc, reply_frame); if (reply_frame != NULL) mpt_dump_reply_frame(mpt, reply_frame); -- You are receiving this mail because: You are the assignee for the bug.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-238661-227>
