]> git.baikalelectronics.ru Git - kernel.git/commit
scsi_dh_alua: uninitialized variable in alua_rtpg()
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 14 Apr 2016 18:20:34 +0000 (21:20 +0300)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Sat, 30 Apr 2016 16:24:50 +0000 (09:24 -0700)
commit99657c826d695ceab5572dcfd4a57add85b99f5a
tree15a0cec934f2f9913de30de68773d1611349a32f
parent29117ef53592e44617a5e92e9234f15273b7ba82
scsi_dh_alua: uninitialized variable in alua_rtpg()

It's possible to use "err" without initializing it.  If it happens to be
a 2 which is SCSI_DH_RETRY then that could cause a bug.  Bart Van Assche
pointed out that we should probably re-initialize it for every iteration
through the retry loop.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Hannes Reinicke <hare@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: James Bottomley <jejb@linux.vnet.ibm.com>
drivers/scsi/device_handler/scsi_dh_alua.c