mpegtsbase: do not access variable after unref
Data might not exist anymore
This commit is contained in:
parent
06d9b61fc2
commit
d91f5e85e7
@ -1039,6 +1039,7 @@ mpegts_base_sink_event (GstPad * pad, GstObject * parent, GstEvent * event)
|
|||||||
gboolean res = TRUE;
|
gboolean res = TRUE;
|
||||||
gboolean hard;
|
gboolean hard;
|
||||||
MpegTSBase *base = GST_MPEGTS_BASE (parent);
|
MpegTSBase *base = GST_MPEGTS_BASE (parent);
|
||||||
|
gboolean is_sticky = GST_EVENT_IS_STICKY (event);
|
||||||
|
|
||||||
GST_DEBUG_OBJECT (base, "Got event %s",
|
GST_DEBUG_OBJECT (base, "Got event %s",
|
||||||
gst_event_type_get_name (GST_EVENT_TYPE (event)));
|
gst_event_type_get_name (GST_EVENT_TYPE (event)));
|
||||||
@ -1078,7 +1079,7 @@ mpegts_base_sink_event (GstPad * pad, GstObject * parent, GstEvent * event)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Always return TRUE for sticky events */
|
/* Always return TRUE for sticky events */
|
||||||
if (GST_EVENT_IS_STICKY (event))
|
if (is_sticky)
|
||||||
res = TRUE;
|
res = TRUE;
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user