From f44314c029583b84ac1a5ec4f244103b5167a84f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Mon, 27 Feb 2017 19:24:07 +0200 Subject: [PATCH] vorbispay: Only replace headers when receiving a new config header If we also replace all headers when receiving any possibly following comments header, we would throw away the config header before being able to make use of it. --- gst/rtp/gstrtpvorbispay.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gst/rtp/gstrtpvorbispay.c b/gst/rtp/gstrtpvorbispay.c index 81bd7320ea..6864f41b10 100644 --- a/gst/rtp/gstrtpvorbispay.c +++ b/gst/rtp/gstrtpvorbispay.c @@ -780,10 +780,10 @@ gst_rtp_vorbis_pay_handle_buffer (GstRTPBasePayload * basepayload, /* we need to collect the headers and construct a config string from them */ if (VDT != 0) { - if (!rtpvorbispay->need_headers) { + if (!rtpvorbispay->need_headers && VDT == 1) { GST_INFO_OBJECT (rtpvorbispay, "getting new headers, replace existing"); g_list_free_full (rtpvorbispay->headers, - (GDestroyNotify) gst_buffer_unref); + (GDestroyNotify) gst_buffer_unref); rtpvorbispay->headers = NULL; rtpvorbispay->need_headers = TRUE; }