Fix resource leak 73/308473/1 accepted/tizen/unified/20240327.064211 accepted/tizen/unified/x/20240401.142309
authorJaehyun Kim <jeik01.kim@samsung.com>
Tue, 26 Mar 2024 07:29:50 +0000 (16:29 +0900)
committerJaehyun Kim <jeik01.kim@samsung.com>
Tue, 26 Mar 2024 07:31:42 +0000 (16:31 +0900)
Change-Id: Ie7628eaa20fed0c1d9c5620e30ad5bd1363c7000
Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
plugin/online-monitor/online-monitor.c
src/utils/setting.c

index a1aab93..6ef04a1 100755 (executable)
@@ -415,6 +415,7 @@ static int init(void)
 
        if (load_configuration(keyfile) != 0) {
                ERR("load_configuration failed");
+               g_key_file_free(keyfile);
                return -1;
        }
 
index ababe3f..e98131b 100755 (executable)
@@ -237,6 +237,8 @@ int netconfig_setting_load(void)
        __setting_get_integer_list(keyfile, SETTINGS_EXTENSION_GROUP_NAME,
                        SETTING_TYPE_IPV4_UDP_BUFFER_SIZE);
 
+       g_key_file_free(keyfile);
+
        return 0;
 }