OSDN Git Service

staging: wlan-ng: Replace data type declaration with variable of same type in p80211c...
authorSergio Paracuellos <sergio.paracuellos@gmail.com>
Mon, 10 Oct 2016 14:02:20 +0000 (16:02 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 16 Oct 2016 08:26:22 +0000 (10:26 +0200)
sizeof(*var) instead of sizeof(struct XXX) is preferred.
Fix it in p80211conv.c file.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wlan-ng/p80211conv.c

index 5c0e658..5080d42 100644 (file)
@@ -615,7 +615,7 @@ int p80211skb_rxmeta_attach(struct wlandevice *wlandev, struct sk_buff *skb)
        }
 
        /* Allocate the rxmeta */
-       rxmeta = kzalloc(sizeof(struct p80211_rxmeta), GFP_ATOMIC);
+       rxmeta = kzalloc(sizeof(*rxmeta), GFP_ATOMIC);
 
        if (!rxmeta) {
                netdev_err(wlandev->netdev,