timecodestamper: Unref latency query after usage

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1249>
This commit is contained in:
Sebastian Dröge 2020-05-06 20:04:17 +03:00
parent 77784c7aba
commit 0dfd05e574

View file

@ -1047,6 +1047,7 @@ gst_timecodestamper_update_latency (GstTimeCodeStamper * timecodestamper,
if (!gst_pad_peer_query (pad, query)) {
GST_WARNING_OBJECT (pad, "Failed to query latency");
gst_pad_mark_reconfigure (pad);
gst_query_unref (query);
return;
}
@ -1059,6 +1060,7 @@ gst_timecodestamper_update_latency (GstTimeCodeStamper * timecodestamper,
"Queried latency: live %d, min latency %" GST_TIME_FORMAT, *live,
GST_TIME_ARGS (*latency));
g_mutex_unlock (&timecodestamper->mutex);
gst_query_unref (query);
}
#endif