[SCSI] sr: remove dead code
authorJayachandran C <jchandra@digeo.com>
Wed, 19 Oct 2005 00:11:16 +0000 (17:11 -0700)
committerJames Bottomley <jejb@mulgrave.(none)>
Fri, 28 Oct 2005 22:42:31 +0000 (17:42 -0500)
This patch fixes an issue reported in drivers/scsi/sr.c by Coverity

Error reported: Pointer returned from "scsi_cd" is never used

Patch description:
 Remove the scsi_cd() call as it does not have any effect.

Signed-off-by: Jayachandran C. <c.jayachandran@gmail.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
drivers/scsi/sr.c

index 9e267c6..3067e5a 100644 (file)
@@ -456,7 +456,7 @@ queue:
 static int sr_block_open(struct inode *inode, struct file *file)
 {
        struct gendisk *disk = inode->i_bdev->bd_disk;
-       struct scsi_cd *cd = scsi_cd(inode->i_bdev->bd_disk);
+       struct scsi_cd *cd;
        int ret = 0;
 
        if(!(cd = scsi_cd_get(disk)))