diff options
author | Samuel Ortiz <sameo@linux.intel.com> | 2011-02-01 18:58:45 +0100 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2011-02-02 18:45:37 +0100 |
commit | 962a98a75e42abde7489cd83a33c1313ad1ae621 (patch) | |
tree | 242f70411a20495b82ea9050660c9efe43ad1d48 /gsupplicant | |
parent | c65767956358ae636cbaf42ac2b6b078317c94b3 (diff) | |
download | connman-962a98a75e42abde7489cd83a33c1313ad1ae621.tar.gz connman-962a98a75e42abde7489cd83a33c1313ad1ae621.tar.bz2 connman-962a98a75e42abde7489cd83a33c1313ad1ae621.zip |
gsupplicant: Add interface ap_scan property setting
Diffstat (limited to 'gsupplicant')
-rw-r--r-- | gsupplicant/gsupplicant.h | 3 | ||||
-rw-r--r-- | gsupplicant/supplicant.c | 16 |
2 files changed, 19 insertions, 0 deletions
diff --git a/gsupplicant/gsupplicant.h b/gsupplicant/gsupplicant.h index 6227ff53..e018adad 100644 --- a/gsupplicant/gsupplicant.h +++ b/gsupplicant/gsupplicant.h @@ -161,6 +161,9 @@ int g_supplicant_interface_disconnect(GSupplicantInterface *interface, GSupplicantInterfaceCallback callback, void *user_data); +int g_supplicant_interface_set_apscan(GSupplicantInterface *interface, + unsigned int ap_scan); + void g_supplicant_interface_set_data(GSupplicantInterface *interface, void *data); void *g_supplicant_interface_get_data(GSupplicantInterface *interface); diff --git a/gsupplicant/supplicant.c b/gsupplicant/supplicant.c index 55c842f4..909dc847 100644 --- a/gsupplicant/supplicant.c +++ b/gsupplicant/supplicant.c @@ -614,6 +614,22 @@ static void interface_capability(const char *key, DBusMessageIter *iter, key, dbus_message_iter_get_arg_type(iter)); } +static void set_apscan(DBusMessageIter *iter, void *user_data) +{ + unsigned int ap_scan = *(unsigned int *)user_data; + + dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT32, &ap_scan); +} + +int g_supplicant_interface_set_apscan(GSupplicantInterface *interface, + unsigned int ap_scan) +{ + return supplicant_dbus_property_set(interface->path, + SUPPLICANT_INTERFACE ".Interface", + "ApScan", DBUS_TYPE_UINT32_AS_STRING, + set_apscan, NULL, &ap_scan); +} + void g_supplicant_interface_set_data(GSupplicantInterface *interface, void *data) { |