summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeongmo Yang <jm80.yang@samsung.com>2021-11-08 15:50:24 +0900
committerJeongmo Yang <jm80.yang@samsung.com>2021-11-08 15:53:13 +0900
commitd28a4481e50fa7b8e7b03dcb491f9929d21f0033 (patch)
tree6054e4030d825630840d1837df0d236cdcb9cb6e
parentb664247d48bd43850de60124aa0ebfd5419ddd27 (diff)
downloadcamera-d28a4481e50fa7b8e7b03dcb491f9929d21f0033.tar.gz
camera-d28a4481e50fa7b8e7b03dcb491f9929d21f0033.tar.bz2
camera-d28a4481e50fa7b8e7b03dcb491f9929d21f0033.zip
Replace g_cond_signal() by g_cond_broadcast()submit/tizen/20211108.090241accepted/tizen/unified/20211109.042919
- It seems that signal could be missed with multi-thread API calls. [Version] 0.4.64 [Issue Type] Enhancement Change-Id: I319c12ab2b1451568aeb86e05642fc69b7952672 Signed-off-by: Jeongmo Yang <jm80.yang@samsung.com>
-rw-r--r--packaging/capi-media-camera.spec2
-rw-r--r--src/camera.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/packaging/capi-media-camera.spec b/packaging/capi-media-camera.spec
index 6e88cae..e16061c 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.4.63
+Version: 0.4.64
Release: 0
Group: Multimedia/API
License: Apache-2.0
diff --git a/src/camera.c b/src/camera.c
index bf560b0..78323e0 100644
--- a/src/camera.c
+++ b/src/camera.c
@@ -1628,7 +1628,7 @@ static gpointer __camera_msg_handler_func(gpointer data)
CAM_LOG_DEBUG("t[%d] camera api[%d] - return[0x%x]", type, api, ret);
- g_cond_signal(&cb_info->api_cond[api]);
+ g_cond_broadcast(&cb_info->api_cond[api]);
} else {
CAM_LOG_WARNING("no waiting for this api [%d]", api);
}
@@ -1925,7 +1925,7 @@ static void __camera_process_msg(camera_cb_info_s *cb_info, char *msg, int *tfd)
cb_info->api_ret[api] = ret;
cb_info->api_activating[api] = TRUE;
- g_cond_signal(&cb_info->api_cond[api]);
+ g_cond_broadcast(&cb_info->api_cond[api]);
} else {
CAM_LOG_WARNING("no waiting for this api [%d]", api);
}