fix svace issues 61/114361/1
authorKyeonghun Lee <kh9090.lee@samsung.com>
Mon, 13 Feb 2017 06:08:19 +0000 (15:08 +0900)
committerKyeonghun Lee <kh9090.lee@samsung.com>
Mon, 13 Feb 2017 06:09:51 +0000 (22:09 -0800)
Change-Id: Ie6934cdf7c56bafa4e6e78e718b4ff2f0a2b7e4a
Signed-off-by: Kyeonghun Lee <kh9090.lee@samsung.com>
utils/MsgJsonParser.cpp

index 49d5fdd..6fce3d8 100755 (executable)
@@ -45,9 +45,9 @@ msg_json_gen_object* msg_json_gen_new_obj(msg_json_gen_type type)
 
                if (new_obj == NULL) {
                        if (type == MSG_JSON_GEN_OBJECT)
-                               g_object_unref(json_value);
+                               json_object_ref((JsonObject *)json_value);
                        else if (type == MSG_JSON_GEN_ARRAY)
-                               g_array_unref((GArray *)json_value);
+                               json_array_unref((JsonArray *)json_value);
 
                        return NULL;
                }
@@ -66,9 +66,9 @@ void msg_json_gen_free_obj(msg_json_gen_object *obj)
        }
        if (obj->value != NULL) {
                if (obj->type == MSG_JSON_GEN_OBJECT)
-                       g_object_unref(obj->value);
+                       json_object_ref((JsonObject *)obj->value);
                else if (obj->type == MSG_JSON_GEN_ARRAY)
-                       g_array_unref((GArray *)obj->value);
+                       json_array_unref((JsonArray *)obj->value);
 
                obj->value = NULL;
        }