[SCSI] gdth: Add missing call to gdth_ioctl_free
authorJulia Lawall <julia@diku.dk>
Wed, 29 Dec 2010 14:57:54 +0000 (15:57 +0100)
committerJames Bottomley <James.Bottomley@suse.de>
Fri, 31 Dec 2010 15:50:09 +0000 (09:50 -0600)
commit5c10007560589a2335a77cbc92347b1474518296
tree662d3e17401bd678a89b82cf635b2719de245917
parent8f4bfadd200477acb6dcf41a45919dd37d01a6db
[SCSI] gdth: Add missing call to gdth_ioctl_free

Add missing call to gdth_ioctl_free before aborting.

The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
expression buf,ha,len,addr,E;
@@

buf = gdth_ioctl_alloc(ha, len, FALSE, &addr)
... when != false buf != NULL
    when != true buf == NULL
    when != \(E = buf\|buf = E\)
    when != gdth_ioctl_free(ha, len, buf, addr)
*return ...;
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/gdth.c
drivers/scsi/gdth_proc.c