dbus: Fix value of BSS Privacy property
authorMarcel Holtmann <marcel@holtmann.org>
Sun, 10 Jan 2010 16:18:08 +0000 (18:18 +0200)
committerJouni Malinen <j@w1.fi>
Sun, 10 Jan 2010 16:18:08 +0000 (18:18 +0200)
Checking for IEEE80211_CAP_PRIVACY needs to use & and not &&.

wpa_supplicant/dbus/dbus_new_handlers.c

index cbcd8fa..9a79257 100644 (file)
@@ -2421,7 +2421,7 @@ DBusMessage * wpas_dbus_getter_bss_privacy(DBusMessage *message,
                return NULL;
        }
 
-       privacy = res->caps && IEEE80211_CAP_PRIVACY ? TRUE : FALSE;
+       privacy = (res->caps & IEEE80211_CAP_PRIVACY) ? TRUE : FALSE;
        return wpas_dbus_simple_property_getter(message, DBUS_TYPE_BOOLEAN,
                                                &privacy);
 }