From 2af45d9ad4475af1602e70e674d23c303c686c62 Mon Sep 17 00:00:00 2001 From: Ronnie Sahlberg Date: Sun, 21 Sep 2014 14:58:12 -0700 Subject: [PATCH] initialize sense to keep valgrind happy valgrind does not know that sense will be initialized by the ioctl so we need to to it explicitely to keep it from warning us. Signed-off-by: Ronnie Sahlberg --- test-tool/iscsi-support.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test-tool/iscsi-support.c b/test-tool/iscsi-support.c index ca4e5e6..889abbc 100644 --- a/test-tool/iscsi-support.c +++ b/test-tool/iscsi-support.c @@ -1,4 +1,3 @@ - /* iscsi-test tool support @@ -200,6 +199,7 @@ static struct scsi_task *send_scsi_command(struct scsi_device *sdev, struct scsi unsigned char sense[sense_len]; char buf[1024]; + memset(sense, 0, sizeof(sense)); memset(&io_hdr, 0, sizeof(sg_io_hdr_t)); io_hdr.interface_id = 'S';