dect
/
linux-2.6
Archived
13
0
Fork 0

caif-hsi: Add missing return in error path

Fix a missing return, causing access to freed memory.

Signed-off-by: Sjur Brændeland <sjur.brandeland@stericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Sjur Brændeland 2012-06-24 11:01:38 +00:00 committed by David S. Miller
parent 3935600a7f
commit 1fdc7630b2
1 changed files with 1 additions and 0 deletions

View File

@ -1178,6 +1178,7 @@ int cfhsi_probe(struct platform_device *pdev)
dev_err(&ndev->dev, "%s: Registration error: %d.\n",
__func__, res);
free_netdev(ndev);
return -ENODEV;
}
/* Add CAIF HSI device to list. */
spin_lock(&cfhsi_list_lock);