Assign NULL after free 79/224779/1 accepted/tizen_6.0_unified accepted/tizen_6.0_unified_hotfix tizen_6.0 tizen_6.0_hotfix accepted/tizen/6.0/unified/20201030.122053 accepted/tizen/6.0/unified/hotfix/20201103.004355 accepted/tizen/6.0/unified/hotfix/20201103.051445 accepted/tizen/unified/20200225.224322 submit/tizen/20200214.070503 submit/tizen/20200224.070517 submit/tizen_6.0/20201029.205102 submit/tizen_6.0_hotfix/20201102.192502 submit/tizen_6.0_hotfix/20201103.114802 tizen_6.0.m2_release
authorCheoleun Moon <chleun.moon@samsung.com>
Thu, 13 Feb 2020 04:38:58 +0000 (13:38 +0900)
committerCheoleun Moon <chleun.moon@samsung.com>
Thu, 13 Feb 2020 04:39:05 +0000 (13:39 +0900)
Change-Id: I51d2ba6fcb73f3a6a8e15a3eb85b610a46316fc9
Signed-off-by: Cheoleun Moon <chleun.moon@samsung.com>
dvpnlib/src/dvpnlib-vpn-connnection.c

index ea364fa..3473a89 100755 (executable)
@@ -264,9 +264,11 @@ static void parse_connection_property_user_routes(
        if (connection->user_routes == NULL) {
                ERROR("connection->server_routes is NULL");
                return;
-       } else
+       } else {
                g_slist_free_full(connection->user_routes,
                                free_vpn_connection_route);
+               connection->user_routes = NULL;
+       }
 
        while (g_variant_iter_loop(&outer, "(a{sv})", &route_entry)) {
                gchar *key;
@@ -334,9 +336,11 @@ static void parse_connection_property_server_routes(
        if (connection->server_routes == NULL) {
                ERROR("connection->server_routes is NULL");
                return;
-       } else
+       } else {
                g_slist_free_full(connection->server_routes,
                                free_vpn_connection_route);
+               connection->server_routes =  NULL;
+       }
 
        while (g_variant_iter_loop(&outer, "(a{sv})", &route_entry)) {
                gchar *key;