mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-21 06:38:19 +00:00
camerabin2: replace deprecated g_atomic_int_exchange_and_add
It was replaced by g_atomic_int_add, which now returns the old value. https://bugzilla.gnome.org/show_bug.cgi?id=659061
This commit is contained in:
parent
cc27a7fe3a
commit
25c3ce9a7a
1 changed files with 7 additions and 1 deletions
|
@ -166,9 +166,15 @@
|
|||
#include <gst/gst-i18n-plugin.h>
|
||||
#include <gst/pbutils/pbutils.h>
|
||||
|
||||
#if GLIB_CHECK_VERSION(2,29,6)
|
||||
#define gst_camerabin2_atomic_int_add g_atomic_int_add
|
||||
#else
|
||||
#define gst_camerabin2_atomic_int_add g_atomic_int_exchange_and_add
|
||||
#endif
|
||||
|
||||
#define GST_CAMERA_BIN2_PROCESSING_INC(c) \
|
||||
{ \
|
||||
gint bef = g_atomic_int_exchange_and_add (&c->processing_counter, 1); \
|
||||
gint bef = gst_camerabin2_atomic_int_add (&c->processing_counter, 1); \
|
||||
if (bef == 0) \
|
||||
g_object_notify (G_OBJECT (c), "idle"); \
|
||||
GST_DEBUG_OBJECT ((c), "Processing counter incremented to: %d", \
|
||||
|
|
Loading…
Reference in a new issue