From caa69229d14d300587789888714c0f9924adf11e Mon Sep 17 00:00:00 2001 From: Kalle Valo Date: Tue, 28 Sep 2010 00:44:34 +0300 Subject: [PATCH] wifi: use const pointer for a ssid buffer A pointer for an ssid buffer was incorrectly stored to a non-const pointer. After fixing this a unneeded cast can be removed. --- plugins/wifi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/wifi.c b/plugins/wifi.c index 984ab0b..a5c10db 100644 --- a/plugins/wifi.c +++ b/plugins/wifi.c @@ -416,7 +416,7 @@ static void network_added(GSupplicantNetwork *supplicant_network) GSupplicantInterface *interface; struct wifi_data *wifi; const char *name, *path, *identifier, *mode, *security, *group; - unsigned char *ssid; + const unsigned char *ssid; unsigned int ssid_len; DBG(""); @@ -433,7 +433,7 @@ static void network_added(GSupplicantNetwork *supplicant_network) if (wifi == NULL) return; - ssid = (unsigned char *)g_supplicant_network_get_ssid(supplicant_network, &ssid_len); + ssid = g_supplicant_network_get_ssid(supplicant_network, &ssid_len); network = connman_device_get_network(wifi->device, path); -- 2.7.4