Fixed dereferencing of the NULL pointer. 87/250287/1 accepted/tizen/6.0/unified/20210107.080322 submit/tizen_6.0/20210105.073751
authorNiraj Kumar Goit <niraj.g@samsung.com>
Wed, 23 Dec 2020 06:29:43 +0000 (11:59 +0530)
committerNiraj Kumar Goit <niraj.g@samsung.com>
Wed, 23 Dec 2020 06:29:43 +0000 (11:59 +0530)
Change-Id: I05fc82a51a3ac53a144309ef86ed052f084d549d
Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
packaging/net-config.spec
src/wifi-config.c

index efd0302..c179d9d 100755 (executable)
@@ -1,6 +1,6 @@
 Name:          net-config
 Summary:       TIZEN Network Configuration service
-Version:       1.2.6
+Version:       1.2.7
 Release:       3
 Group:         System/Network
 License:       Apache-2.0
index f889209..5911505 100755 (executable)
@@ -1050,6 +1050,12 @@ gboolean handle_get_config_ids(Wifi *wifi, GDBusMethodInvocation *context,
        g_return_val_if_fail(wifi != NULL, TRUE);
 
        mac_addr = wifi_state_get_mac_address(ifname);
+       if (!mac_addr) {
+               ERR("Fail to get mac-address");
+               netconfig_error_no_profile(context);
+               return TRUE;
+       }
+
        DBG("%s", mac_addr);
        config_ids = _get_list(mac_addr);
        if (config_ids == NULL) {