summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeongmo Yang <jm80.yang@samsung.com>2017-01-03 15:43:50 +0900
committerJeongmo Yang <jm80.yang@samsung.com>2017-01-03 15:43:50 +0900
commit20599a601328b4c87947b0f6dbf7b5cfe3fdb7b7 (patch)
treed3e3bbea825a9951f7899b41cb9b6479ea01037c
parent1b09e2d8e06370b7a243153db217e80e451b316f (diff)
downloadcamera-20599a601328b4c87947b0f6dbf7b5cfe3fdb7b7.tar.gz
camera-20599a601328b4c87947b0f6dbf7b5cfe3fdb7b7.tar.bz2
camera-20599a601328b4c87947b0f6dbf7b5cfe3fdb7b7.zip
Remove g_thread_unref after g_thread_join
g_thread_unref is also called in g_thread_join, so g_thread_unref after g_thread_join is not needed and it can cause memory corruption. [Version] 0.2.92 [Profile] Common [Issue Type] Bug fix [Dependency module] N/A [Test] [M(T) - Boot=(OK), sdb=(OK), Home=(OK), Touch=(OK), Version=tizen-3.0-mobile_20161230.2] Change-Id: I06b8841d8788a101dd099f58e1356fcfb1ec1885 Signed-off-by: Jeongmo Yang <jm80.yang@samsung.com>
-rw-r--r--packaging/capi-media-camera.spec2
-rw-r--r--src/camera.c2
2 files changed, 1 insertions, 3 deletions
diff --git a/packaging/capi-media-camera.spec b/packaging/capi-media-camera.spec
index 6aa000c..2d8a855 100644
--- a/packaging/capi-media-camera.spec
+++ b/packaging/capi-media-camera.spec
@@ -1,6 +1,6 @@
Name: capi-media-camera
Summary: A Camera API
-Version: 0.2.91
+Version: 0.2.92
Release: 0
Group: Multimedia/API
License: Apache-2.0
diff --git a/src/camera.c b/src/camera.c
index 6388caa..7088bf3 100644
--- a/src/camera.c
+++ b/src/camera.c
@@ -2177,7 +2177,6 @@ static void __destroy_msg_handler_thread(camera_msg_handler_info_s *handler_info
g_mutex_unlock(&handler_info->mutex);
g_thread_join(handler_info->thread);
- g_thread_unref(handler_info->thread);
handler_info->thread = NULL;
g_mutex_clear(&handler_info->mutex);
@@ -2294,7 +2293,6 @@ static void _camera_client_callback_destroy(camera_cb_info_s *cb_info)
LOGD("msg_recv thread[%p] destroy", cb_info->msg_recv_thread);
g_thread_join(cb_info->msg_recv_thread);
- g_thread_unref(cb_info->msg_recv_thread);
cb_info->msg_recv_thread = NULL;
LOGD("msg_recv thread removed");