summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVineeth TM <vineeth.tm@samsung.com>2015-11-16 16:56:04 +0900
committerSebastian Dröge <sebastian@centricular.com>2015-11-16 10:22:16 +0200
commit0d4e3847f0c9106ed345f0316e4954f82332e250 (patch)
treef1c6ad2fa5237e6718d3e508c7c6f0345bf4168a
parent8ef6ecc244285161ce5d12dfd1e6fda2c55c329c (diff)
qtdemux: Fix string memory leak
The string got using g_strdup_printf will be allocated memory and should be freed after use. https://bugzilla.gnome.org/show_bug.cgi?id=758161
-rw-r--r--gst/isomp4/qtdemux.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gst/isomp4/qtdemux.c b/gst/isomp4/qtdemux.c
index 19ecaacea..d89cfd041 100644
--- a/gst/isomp4/qtdemux.c
+++ b/gst/isomp4/qtdemux.c
@@ -12473,6 +12473,7 @@ qtdemux_video_caps (GstQTDemux * qtdemux, QtDemuxStream * stream,
g_snprintf (fourstr, 5, "%" GST_FOURCC_FORMAT, GST_FOURCC_ARGS (fourcc));
s = g_strdup_printf ("video/x-gst-fourcc-%s", g_strstrip (fourstr));
caps = gst_caps_new_empty_simple (s);
+ g_free (s);
break;
}
}
@@ -12762,6 +12763,7 @@ qtdemux_audio_caps (GstQTDemux * qtdemux, QtDemuxStream * stream,
g_snprintf (fourstr, 5, "%" GST_FOURCC_FORMAT, GST_FOURCC_ARGS (fourcc));
s = g_strdup_printf ("audio/x-gst-fourcc-%s", g_strstrip (fourstr));
caps = gst_caps_new_empty_simple (s);
+ g_free (s);
break;
}
}
@@ -12822,6 +12824,7 @@ qtdemux_sub_caps (GstQTDemux * qtdemux, QtDemuxStream * stream,
g_snprintf (fourstr, 5, "%" GST_FOURCC_FORMAT, GST_FOURCC_ARGS (fourcc));
s = g_strdup_printf ("text/x-gst-fourcc-%s", g_strstrip (fourstr));
caps = gst_caps_new_empty_simple (s);
+ g_free (s);
break;
}
}