From: Samuel Ortiz Date: Mon, 31 Jan 2011 15:38:48 +0000 (+0100) Subject: gsupplicant: Add interface mode capability getter X-Git-Tag: 0.69~24 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fupstream%2Fconnman.git;a=commitdiff_plain;h=27724d297b0a11d12f46a121a1982617c9ccf7af gsupplicant: Add interface mode capability getter --- diff --git a/gsupplicant/gsupplicant.h b/gsupplicant/gsupplicant.h index c2462f4..2ed8af6 100644 --- a/gsupplicant/gsupplicant.h +++ b/gsupplicant/gsupplicant.h @@ -168,6 +168,7 @@ const char *g_supplicant_interface_get_wps_key(GSupplicantInterface *interface); const void *g_supplicant_interface_get_wps_ssid(GSupplicantInterface *interface, unsigned int *ssid_len); GSupplicantWpsState g_supplicant_interface_get_wps_state(GSupplicantInterface *interface); +unsigned int g_supplicant_interface_get_mode(GSupplicantInterface *interface); /* Network API */ struct _GSupplicantNetwork; diff --git a/gsupplicant/supplicant.c b/gsupplicant/supplicant.c index 2e17868..48a176a 100644 --- a/gsupplicant/supplicant.c +++ b/gsupplicant/supplicant.c @@ -688,6 +688,14 @@ GSupplicantWpsState g_supplicant_interface_get_wps_state( return interface->wps_state; } +unsigned int g_supplicant_interface_get_mode(GSupplicantInterface *interface) +{ + if (interface == NULL) + return 0; + + return interface->mode_capa; +} + GSupplicantInterface *g_supplicant_network_get_interface( GSupplicantNetwork *network) {