Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/1136 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2660>