Commit 5c94afd7 authored by Jirka Pirko's avatar Jirka Pirko Committed by David S. Miller

tokenring/3c359.c: Prevent possible mem leak when open failed

Freeing previously allocated buffers in case of error.
Signed-off-by: default avatarJirka Pirko <>
Signed-off-by: default avatarDavid S. Miller <>
parent 138a5cdf
......@@ -669,6 +669,8 @@ static int xl_open(struct net_device *dev)
if (i==0) {
printk(KERN_WARNING "%s: Not enough memory to allocate rx buffers. Adapter disabled \n",dev->name) ;
free_irq(dev->irq,dev) ;
return -EIO ;
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment