Show Networks property only for wireless devices
authorMarcel Holtmann <marcel@holtmann.org>
Fri, 5 Dec 2008 22:54:26 +0000 (23:54 +0100)
committerMarcel Holtmann <marcel@holtmann.org>
Fri, 5 Dec 2008 22:54:26 +0000 (23:54 +0100)
src/element.c

index 0aef003..00da43a 100644 (file)
@@ -362,6 +362,10 @@ static void append_networks(struct connman_element *element,
        DBusMessageIter entry, value, iter;
        const char *key = "Networks";
 
+       if (element->subtype != CONNMAN_ELEMENT_SUBTYPE_WIFI &&
+                       element->subtype != CONNMAN_ELEMENT_SUBTYPE_WIMAX)
+               return;
+
        dbus_message_iter_open_container(dict, DBUS_TYPE_DICT_ENTRY,
                                                                NULL, &entry);