summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorNicolas Dufresne <nicolas.dufresne@collabora.co.uk>2013-05-25 22:03:53 -0400
committerNicolas Dufresne <nicolas.dufresne@collabora.co.uk>2013-05-25 22:03:53 -0400
commit5bbc6f1c8c7adbc9b7dd9fdd2b461b097f0d089c (patch)
tree9ad62197a52fb7f8afa2a97f747e39a9614a6b4a /plugins
parent789b68e5065c0e5cd280e627c0ebb8ace162fbf9 (diff)
valve: Don't read sticky flag from unrefed event
Diffstat (limited to 'plugins')
-rw-r--r--plugins/elements/gstvalve.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/elements/gstvalve.c b/plugins/elements/gstvalve.c
index 61197ff8a..54a903885 100644
--- a/plugins/elements/gstvalve.c
+++ b/plugins/elements/gstvalve.c
@@ -223,12 +223,13 @@ static gboolean
gst_valve_event (GstPad * pad, GstObject * parent, GstEvent * event)
{
GstValve *valve;
+ gboolean is_sticky = GST_EVENT_IS_STICKY (event);
gboolean ret = TRUE;
valve = GST_VALVE (parent);
if (g_atomic_int_get (&valve->drop)) {
- valve->need_repush_sticky |= GST_EVENT_IS_STICKY (event);
+ valve->need_repush_sticky |= is_sticky;
gst_event_unref (event);
} else {
if (valve->need_repush_sticky)
@@ -240,7 +241,7 @@ gst_valve_event (GstPad * pad, GstObject * parent, GstEvent * event)
* downwards.
*/
if (g_atomic_int_get (&valve->drop)) {
- valve->need_repush_sticky |= GST_EVENT_IS_STICKY (event);
+ valve->need_repush_sticky |= is_sticky;
ret = TRUE;
}