mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-01 14:11:15 +00:00
pad: Check data NULL-ness when probes are stopped
We were correctly handling this for buffers, but not events and queries. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7506>
This commit is contained in:
parent
eea3df38fc
commit
78635ce0cd
1 changed files with 3 additions and 3 deletions
|
@ -4567,7 +4567,7 @@ probe_handled:
|
||||||
probe_stopped:
|
probe_stopped:
|
||||||
{
|
{
|
||||||
/* We unref the buffer, except if the probe handled it (CUSTOM_SUCCESS_1) */
|
/* We unref the buffer, except if the probe handled it (CUSTOM_SUCCESS_1) */
|
||||||
if (!handled)
|
if (data && !handled)
|
||||||
gst_mini_object_unref (GST_MINI_OBJECT_CAST (data));
|
gst_mini_object_unref (GST_MINI_OBJECT_CAST (data));
|
||||||
|
|
||||||
switch (ret) {
|
switch (ret) {
|
||||||
|
@ -5636,7 +5636,7 @@ inactive:
|
||||||
probe_stopped:
|
probe_stopped:
|
||||||
{
|
{
|
||||||
GST_OBJECT_FLAG_SET (pad, GST_PAD_FLAG_PENDING_EVENTS);
|
GST_OBJECT_FLAG_SET (pad, GST_PAD_FLAG_PENDING_EVENTS);
|
||||||
if (ret != GST_FLOW_CUSTOM_SUCCESS_1)
|
if (event && ret != GST_FLOW_CUSTOM_SUCCESS_1)
|
||||||
gst_event_unref (event);
|
gst_event_unref (event);
|
||||||
|
|
||||||
switch (ret) {
|
switch (ret) {
|
||||||
|
@ -6045,7 +6045,7 @@ probe_stopped:
|
||||||
if (need_unlock)
|
if (need_unlock)
|
||||||
GST_PAD_STREAM_UNLOCK (pad);
|
GST_PAD_STREAM_UNLOCK (pad);
|
||||||
/* Only unref if unhandled */
|
/* Only unref if unhandled */
|
||||||
if (ret != GST_FLOW_CUSTOM_SUCCESS_1)
|
if (event && ret != GST_FLOW_CUSTOM_SUCCESS_1)
|
||||||
gst_event_unref (event);
|
gst_event_unref (event);
|
||||||
|
|
||||||
switch (ret) {
|
switch (ret) {
|
||||||
|
|
Loading…
Reference in a new issue