summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gst/gstpad.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/gst/gstpad.c b/gst/gstpad.c
index 5938744c1..35ecd1619 100644
--- a/gst/gstpad.c
+++ b/gst/gstpad.c
@@ -4899,11 +4899,13 @@ gst_pad_get_sticky_event (GstPad * pad, GstEventType event_type,
idx = GST_EVENT_STICKY_IDX_TYPE (event_type);
+ GST_OBJECT_LOCK (pad);
if (!active || pad->priv->events[idx].active) {
if ((event = pad->priv->events[idx].event)) {
gst_event_ref (event);
}
}
+ GST_OBJECT_UNLOCK (pad);
return event;
}