[SCSI] libfc:prevent dereferencing ERR_PTR in fc_tm_done()
authorDan Carpenter <error27@gmail.com>
Sat, 29 Jan 2011 00:03:31 +0000 (16:03 -0800)
committerJames Bottomley <James.Bottomley@suse.de>
Sat, 12 Feb 2011 16:57:54 +0000 (10:57 -0600)
If we goto out, then it tries to call kfree_skb() on an ERR_PTR which
will oops.  Just return directly.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/libfc/fc_fcp.c

index ba639fad0a1c7ab3ad5c5aaa4ef702b3a83f342c..f4eb1ab7b28884541d37d92c92dcfd478b47487c 100644 (file)
@@ -1323,7 +1323,7 @@ static void fc_tm_done(struct fc_seq *seq, struct fc_frame *fp, void *arg)
                 *
                 * scsi-eh will escalate for when either happens.
                 */
-               goto out;
+               return;
        }
 
        if (fc_fcp_lock_pkt(fsp))