Add missing dbus method result unref 14/246514/1
authorSeungbae Shin <seungbae.shin@samsung.com>
Fri, 30 Oct 2020 10:06:01 +0000 (19:06 +0900)
committerSeungbae Shin <seungbae.shin@samsung.com>
Fri, 30 Oct 2020 10:10:04 +0000 (19:10 +0900)
[Version] 0.10.223
[Issue Type] Bug

Change-Id: If4196631e9335fb9556196547bcf6d7de0f155d0

packaging/libmm-camcorder.spec
src/mm_camcorder_util.c

index 9cfdae1..9dd6d06 100755 (executable)
@@ -1,6 +1,6 @@
 Name:       libmm-camcorder
 Summary:    Camera and recorder library
-Version:    0.10.222
+Version:    0.10.223
 Release:    0
 Group:      Multimedia/Libraries
 License:    Apache-2.0
index 983e386..3114bc0 100644 (file)
@@ -893,6 +893,7 @@ int _mmcamcorder_get_device_flash_brightness(GDBusConnection *conn, int *brightn
                g_variant_get(result, "(i)", &get_value);
                *brightness = get_value;
                MMCAM_LOG_INFO("flash brightness : %d", *brightness);
+               g_variant_unref(result);
        } else {
                MMCAM_LOG_ERROR("replied result is null");
                ret = MM_ERROR_CAMCORDER_INTERNAL;
@@ -929,6 +930,7 @@ int _mmcamcorder_send_sound_play_message(GDBusConnection *conn, _MMCamcorderGDbu
        if (result) {
                g_variant_get(result, "(i)", &get_value);
                MMCAM_LOG_INFO("played index : %d", get_value);
+               g_variant_unref(result);
        } else {
                MMCAM_LOG_ERROR("replied result is null");
                return MM_ERROR_CAMCORDER_INTERNAL;
@@ -990,6 +992,7 @@ void _mmcamcorder_request_dpm_popup(GDBusConnection *conn, const char *restricte
        if (result) {
                g_variant_get(result, "(b)", &get_value);
                MMCAM_LOG_INFO("request result : %d", get_value);
+               g_variant_unref(result);
        } else {
                MMCAM_LOG_ERROR("replied result is null");
        }