rtspreal: fix minor memory leak
Caps take their own reference when a buffer is added to them, so unref buffer after adding it to caps (#608533).
This commit is contained in:
parent
29c509a7b8
commit
4cb5f32308
@ -593,7 +593,9 @@ rtsp_ext_real_parse_sdp (GstRTSPExtension * ext, GstSDPMessage * sdp,
|
|||||||
GST_BUFFER_SIZE (buf) = offset;
|
GST_BUFFER_SIZE (buf) = offset;
|
||||||
|
|
||||||
/* Set on caps */
|
/* Set on caps */
|
||||||
|
GST_BUFFER_FLAG_SET (buf, GST_BUFFER_FLAG_IN_CAPS);
|
||||||
gst_structure_set (props, "config", GST_TYPE_BUFFER, buf, NULL);
|
gst_structure_set (props, "config", GST_TYPE_BUFFER, buf, NULL);
|
||||||
|
gst_buffer_unref (buf);
|
||||||
|
|
||||||
/* Overwrite encoding and media fields */
|
/* Overwrite encoding and media fields */
|
||||||
gst_structure_set (props, "encoding-name", G_TYPE_STRING, "X-REAL-RDT", NULL);
|
gst_structure_set (props, "encoding-name", G_TYPE_STRING, "X-REAL-RDT", NULL);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user