]> nv-tegra.nvidia Code Review - linux-2.6.git/commitdiff
[SCSI] fix double free of scsi request queue
authorBrian King <brking@us.ibm.com>
Mon, 12 Dec 2005 19:05:08 +0000 (13:05 -0600)
committerJames Bottomley <jejb@mulgrave.(none)>
Mon, 12 Dec 2005 20:27:05 +0000 (14:27 -0600)
Current scsi scanning code appears to have a use after free
bug is a LLDD's slave_alloc fails. Remove the redundant
scsi_free_queue.

Signed-off-by: Brian King <brking@us.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
drivers/scsi/scsi_scan.c

index 374853df9cca10fb733b9eff4ffc8aa373ee5ffc..be276ea8f033330d72cb631233c8801a27d7eced 100644 (file)
@@ -279,7 +279,6 @@ static struct scsi_device *scsi_alloc_sdev(struct scsi_target *starget,
 
 out_device_destroy:
        transport_destroy_device(&sdev->sdev_gendev);
-       scsi_free_queue(sdev->request_queue);
        put_device(&sdev->sdev_gendev);
 out:
        if (display_failure_msg)