svn commit: r281961 - stable/10/sys/cam/scsi
Pedro F. Giffuni
pfg at FreeBSD.org
Sat Apr 25 00:58:20 UTC 2015
Author: pfg
Date: Sat Apr 25 00:58:19 2015
New Revision: 281961
URL: https://svnweb.freebsd.org/changeset/base/281961
Log:
MFC r281795:
scsi_parse_transportid_rdma(): fix mismatch in memory access size.
Independently found by Coverity and gcc49.
CID: 1230006
Reviewed by: ken
Modified:
stable/10/sys/cam/scsi/scsi_all.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sys/cam/scsi/scsi_all.c
==============================================================================
--- stable/10/sys/cam/scsi/scsi_all.c Sat Apr 25 00:52:01 2015 (r281960)
+++ stable/10/sys/cam/scsi/scsi_all.c Sat Apr 25 00:58:19 2015 (r281961)
@@ -6039,7 +6039,7 @@ scsi_parse_transportid_rdma(char *id_str
goto bailout;
}
*alloc_len = sizeof(*rdma);
- bzero(rdma, sizeof(rdma));
+ bzero(rdma, *alloc_len);
rdma->format_protocol = SCSI_PROTO_RDMA | SCSI_TRN_RDMA_FORMAT_DEFAULT;
bcopy(rdma_id, rdma->initiator_port_id, SCSI_TRN_RDMA_PORT_LEN);
More information about the svn-src-stable-10
mailing list