Fix double free 70/216270/2 accepted/tizen/unified/20191104.115318 submit/tizen/20191031.060909 submit/tizen/20191101.045457
authorINSUN PYO <insun.pyo@samsung.com>
Tue, 22 Oct 2019 23:42:50 +0000 (08:42 +0900)
committerINSUN PYO <insun.pyo@samsung.com>
Wed, 23 Oct 2019 00:06:39 +0000 (09:06 +0900)
Change-Id: Ic2e4235a6806644060ac25ab7be49f9ac417370c

client/cal_client_dbus.c

index d03e29e..a15025b 100644 (file)
@@ -691,8 +691,6 @@ int cal_dbus_get_records_with_query(calendar_h handle, calendar_query_h query,
                else
                        ret = CALENDAR_ERROR_IPC;
                g_error_free(error);
-               g_variant_unref(arg_query);
-               g_variant_unref(arg_handle);
                g_variant_unref(arg_list);
                return ret;
                /* LCOV_EXCL_STOP */
@@ -702,8 +700,6 @@ int cal_dbus_get_records_with_query(calendar_h handle, calendar_query_h query,
        if (*out_list)
                calendar_list_first(*out_list);
 
-       g_variant_unref(arg_query);
-       g_variant_unref(arg_handle);
        g_variant_unref(arg_list);
 
        return ret;
@@ -846,14 +842,12 @@ int cal_dbus_get_current_version(calendar_h handle, int *out_version)
                        ret = CALENDAR_ERROR_IPC;
                g_error_free(error);
 
-               g_variant_unref(arg_handle);
                return ret;
                /* LCOV_EXCL_STOP */
        }
 
        *out_version = version;
 
-       g_variant_unref(arg_handle);
        return ret;
 }