Commit 799cc2cf authored by Dave Jones's avatar Dave Jones Committed by Linus Torvalds

[PATCH] Fix leak in atmel wireless driver.

Spotted with the source checker from Coverity.com.
Signed-off-by: default avatarDave Jones <davej@redhat.com>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 1c582040
...@@ -2432,6 +2432,7 @@ static int atmel_ioctl(struct net_device *dev, struct ifreq *rq, int cmd) ...@@ -2432,6 +2432,7 @@ static int atmel_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
} }
if (copy_from_user(new_firmware, com.data, com.len)) { if (copy_from_user(new_firmware, com.data, com.len)) {
kfree(new_firmware);
rc = -EFAULT; rc = -EFAULT;
break; break;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment