[Crash Fix] Set global list variables back to NULL after g_slist_free_full() operation. accepted/tizen/unified/20190929.221445 submit/tizen/20190927.055416
authorNishant Chaprana <n.chaprana@samsung.com>
Thu, 26 Sep 2019 13:31:41 +0000 (19:01 +0530)
committersaerome.kim <saerome.kim@samsung.com>
Fri, 27 Sep 2019 05:52:37 +0000 (14:52 +0900)
Change-Id: I219130622e4d5471cf6f9ee6b30f911c8ff44d83
Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
src/user-awareness-event-handler.c

index 62c0fa748c666470d5c72d1ae834264d2ae295b8..69114639a6470bcf76a630f2353c2b83c9c290e9 100644 (file)
@@ -310,10 +310,16 @@ int ua_deinitialize(void)
        retv_if(TRUE != is_initialized, UA_ERROR_NOT_INITIALIZED);
 
        g_slist_free_full(ua_services_list, _ua_free_ua_service_info_s);
+       ua_services_list = NULL;
+
        g_slist_free_full(ua_monitor_list, _ua_free_ua_monitor_t);
+       ua_monitor_list = NULL;
+
        g_slist_free_full(ua_users_list, _ua_free_ua_user_info_t);
-       g_slist_free_full(ua_devices_db_list, _ua_free_ua_device_info_t);
+       ua_users_list = NULL;
 
+       g_slist_free_full(ua_devices_db_list, _ua_free_ua_device_info_t);
+       ua_devices_db_list = NULL;
 
        ret = _ua_get_error_code(_uam_deinit());
        if (UA_ERROR_NONE != ret) {