summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Vogelgesang <matthias.vogelgesang@kit.edu>2016-12-19 15:09:15 +0100
committerMatthias Vogelgesang <matthias.vogelgesang@kit.edu>2016-12-19 15:09:15 +0100
commit98ab1c3f5254d6ad9e5cbfc90c8406ddcf05e278 (patch)
tree23ee672b3b01095e4fae08868784ef76034267f8
parentbf58fe70946c11e655ed4e80906de2fb15aa91d5 (diff)
downloaduca-98ab1c3f5254d6ad9e5cbfc90c8406ddcf05e278.tar.gz
uca-98ab1c3f5254d6ad9e5cbfc90c8406ddcf05e278.tar.bz2
uca-98ab1c3f5254d6ad9e5cbfc90c8406ddcf05e278.tar.xz
uca-98ab1c3f5254d6ad9e5cbfc90c8406ddcf05e278.zip
mock: use g_thread_new for GLib >= 2.32
-rw-r--r--plugins/mock/uca-mock-camera.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/mock/uca-mock-camera.c b/plugins/mock/uca-mock-camera.c
index 611787d..d886378 100644
--- a/plugins/mock/uca-mock-camera.c
+++ b/plugins/mock/uca-mock-camera.c
@@ -279,7 +279,11 @@ uca_mock_camera_start_recording(UcaCamera *camera, GError **error)
if (transfer_async) {
GError *tmp_error = NULL;
priv->thread_running = TRUE;
- priv->grab_thread = g_thread_create(mock_grab_func, camera, TRUE, &tmp_error);
+#if GLIB_CHECK_VERSION (2, 32, 0)
+ priv->grab_thread = g_thread_new (NULL, mock_grab_func, camera);
+#else
+ priv->grab_thread = g_thread_create (mock_grab_func, camera, TRUE, &tmp_error);
+#endif
if (tmp_error != NULL) {
priv->thread_running = FALSE;