rndis_wlan: avoid uninitialized var warning in rndis_wlan_craft_connected_bss
authorJohn W. Linville <linville@tuxdriver.com>
Tue, 16 Nov 2010 21:49:08 +0000 (16:49 -0500)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 18 Nov 2010 19:22:22 +0000 (14:22 -0500)
  CC [M]  drivers/net/wireless/rndis_wlan.o
drivers/net/wireless/rndis_wlan.c: In function ‘rndis_wlan_craft_connected_bss’:
drivers/net/wireless/rndis_wlan.c:2542:2: warning: ‘ret’ may be used uninitialized in this function

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi>
drivers/net/wireless/rndis_wlan.c

index 8a77ff6..ee08bca 100644 (file)
@@ -2536,7 +2536,7 @@ static void rndis_wlan_craft_connected_bss(struct usbnet *usbdev, u8 *bssid,
        /* Get signal quality, in case of error use rssi=0 and ignore error. */
        len = sizeof(rssi);
        rssi = 0;
-       rndis_query_oid(usbdev, OID_802_11_RSSI, &rssi, &len);
+       ret = rndis_query_oid(usbdev, OID_802_11_RSSI, &rssi, &len);
        signal = level_to_qual(le32_to_cpu(rssi));
 
        netdev_dbg(usbdev->net, "%s(): OID_802_11_RSSI -> %d, "