From d105de6e0f2326932dac8d9748dff14ce0abf536 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Sebastian=20Dr=C3=B6ge?= Date: Wed, 4 Dec 2013 21:57:04 +0100 Subject: [PATCH] rtptheorapay: Don't leak config data when receiving a second CAPS event --- gst/rtp/gstrtptheorapay.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gst/rtp/gstrtptheorapay.c b/gst/rtp/gstrtptheorapay.c index 7e00216..379e04d 100644 --- a/gst/rtp/gstrtptheorapay.c +++ b/gst/rtp/gstrtptheorapay.c @@ -507,6 +507,8 @@ gst_rtp_theora_pay_finish_headers (GstRTPBasePayload * basepayload) configuration = g_base64_encode (config, configlen); /* store for later re-sending */ + if (rtptheorapay->config_data) + g_free (rtptheorapay->config_data); rtptheorapay->config_size = configlen - 4 - 3 - 2; rtptheorapay->config_data = g_malloc (rtptheorapay->config_size); rtptheorapay->config_extra_len = extralen; -- 2.7.4