From: Julia Lawall Date: Sun, 22 Apr 2012 12:02:13 +0000 (+0200) Subject: drivers/staging/rtl8192u/ieee80211/ieee80211_module.c: add missing free_netdev X-Git-Tag: v3.12-rc1~3149^2~229^2~100 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=89f5e7102a56bcd1b5b0691085d0839e92b3ca04;p=kernel%2Fkernel-generic.git drivers/staging/rtl8192u/ieee80211/ieee80211_module.c: add missing free_netdev Free dev on failure as done elsewhere in the function. Signed-off-by: Julia Lawall Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8192u/ieee80211/ieee80211_module.c b/drivers/staging/rtl8192u/ieee80211/ieee80211_module.c index e3d47bc..82d4bf6 100644 --- a/drivers/staging/rtl8192u/ieee80211/ieee80211_module.c +++ b/drivers/staging/rtl8192u/ieee80211/ieee80211_module.c @@ -161,7 +161,7 @@ struct net_device *alloc_ieee80211(int sizeof_priv) if (ieee->pHTInfo == NULL) { IEEE80211_DEBUG(IEEE80211_DL_ERR, "can't alloc memory for HTInfo\n"); - return NULL; + goto failed; } HTUpdateDefaultSetting(ieee); HTInitializeHTInfo(ieee); //may move to other place.