summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorMayank Haarit <mayank.h@samsung.com>2018-04-18 19:59:49 +0530
committerMayank Haarit <mayank.h@samsung.com>2018-04-20 19:34:29 +0530
commitdce2054780e8142aebe5a7d11c4751040437f7ec (patch)
treecbbe0c26f6956b267d8192e409e13c66b966505a /plugins
parentf08451dc1450406af7f5db6d3cd2f49e1da33836 (diff)
downloadconnman-dce2054780e8142aebe5a7d11c4751040437f7ec.tar.gz
connman-dce2054780e8142aebe5a7d11c4751040437f7ec.tar.bz2
connman-dce2054780e8142aebe5a7d11c4751040437f7ec.zip
Added logic to get country code of APs
It also includes parsing country code from IEs received from the supplicant Change-Id: Iea5f8b2ea7cc8fefe07591cc4d636d27b015d427 Signed-off-by: Mayank Haarit <mayank.h@samsung.com>
Diffstat (limited to 'plugins')
-rwxr-xr-xplugins/wifi.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/wifi.c b/plugins/wifi.c
index a9ffad05..91732bd0 100755
--- a/plugins/wifi.c
+++ b/plugins/wifi.c
@@ -3417,6 +3417,7 @@ static void network_added(GSupplicantNetwork *supplicant_network)
#if defined TIZEN_EXT
GSList *vsie_list = NULL;
+ const unsigned char *country_code;
#endif
mode = g_supplicant_network_get_mode(supplicant_network);
@@ -3472,6 +3473,8 @@ static void network_added(GSupplicantNetwork *supplicant_network)
connman_network_set_vsie_list(network, vsie_list);
else
DBG("vsie_list is NULL");
+ country_code = g_supplicant_network_get_countrycode(supplicant_network);
+ connman_network_set_countrycode(network, country_code);
#endif
connman_network_set_string(network, "WiFi.Security", security);
connman_network_set_strength(network,
@@ -3593,6 +3596,7 @@ static void network_changed(GSupplicantNetwork *network, const char *property)
unsigned int maxrate;
uint16_t frequency;
bool wps;
+ const unsigned char *country_code;
#endif
interface = g_supplicant_network_get_interface(network);
@@ -3625,6 +3629,8 @@ static void network_changed(GSupplicantNetwork *network, const char *property)
connman_network_set_maxrate(connman_network, maxrate);
connman_network_set_frequency(connman_network, frequency);
connman_network_set_bool(connman_network, "WiFi.WPS", wps);
+ country_code = g_supplicant_network_get_countrycode(network);
+ connman_network_set_countrycode(connman_network, country_code);
#endif
}