summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2014-06-04 18:21:33 +0000
committerjhb <jhb@FreeBSD.org>2014-06-04 18:21:33 +0000
commit9a61bc9a83c28b7eebe6b74227c76270722d614e (patch)
tree637928d427ba0433a00f63e2edf07c9cd5123f3e
parent9464d250b6fdaf4bd5e0a0043ba8b5a681236c53 (diff)
downloadFreeBSD-src-9a61bc9a83c28b7eebe6b74227c76270722d614e.zip
FreeBSD-src-9a61bc9a83c28b7eebe6b74227c76270722d614e.tar.gz
MFC 266281:
Clear the data buffer length field when freeing a command structure so that it doesn't leak through when the command structure is reused for a user command without a data buffer. PR: 189668
-rw-r--r--sys/dev/aac/aac.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/dev/aac/aac.c b/sys/dev/aac/aac.c
index c0f11f9..3ea964f 100644
--- a/sys/dev/aac/aac.c
+++ b/sys/dev/aac/aac.c
@@ -1408,6 +1408,7 @@ aac_release_command(struct aac_command *cm)
fwprintf(sc, HBA_FLAGS_DBG_FUNCTION_ENTRY_B, "");
/* (re)initialize the command/FIB */
+ cm->cm_datalen = 0;
cm->cm_sgtable = NULL;
cm->cm_flags = 0;
cm->cm_complete = NULL;
OpenPOWER on IntegriCloud