From d24d1e40ea33cb402929dc6d57d634acbd1daa3d Mon Sep 17 00:00:00 2001 From: Thiago Sousa Santos Date: Tue, 17 Nov 2009 09:26:05 -0300 Subject: [PATCH] qtmux: do not leak a string Frees a string after use. Also does some code organization --- gst/quicktime/gstqtmux.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/gst/quicktime/gstqtmux.c b/gst/quicktime/gstqtmux.c index 2e873c9d8f..6b650b204a 100644 --- a/gst/quicktime/gstqtmux.c +++ b/gst/quicktime/gstqtmux.c @@ -221,18 +221,19 @@ gst_qt_mux_class_init (GstQTMuxClass * klass) g_object_class_install_property (gobject_class, PROP_DO_CTTS, g_param_spec_boolean ("presentation-time", "Include presentation-time info", - "Calculate and include presentation/composition time (in addition to decoding time)" - " (use with caution)", DEFAULT_DO_CTTS, - G_PARAM_READWRITE | G_PARAM_CONSTRUCT)); + "Calculate and include presentation/composition time " + "(in addition to decoding time) (use with caution)", + DEFAULT_DO_CTTS, G_PARAM_READWRITE | G_PARAM_CONSTRUCT)); g_object_class_install_property (gobject_class, PROP_FAST_START, g_param_spec_boolean ("faststart", "Format file to faststart", "If the file should be formated for faststart (headers first). ", DEFAULT_FAST_START, G_PARAM_READWRITE)); g_object_class_install_property (gobject_class, PROP_FAST_START_TEMP_FILE, g_param_spec_string ("faststart-file", "File to use for storing buffers", - "File that will be used temporarily to store data from the stream when " - "creating a faststart file. If null a filepath will be created automatically", - DEFAULT_FAST_START_TEMP_FILE, G_PARAM_READWRITE | G_PARAM_CONSTRUCT)); + "File that will be used temporarily to store data from the stream " + "when creating a faststart file. If null a filepath will be " + "created automatically", DEFAULT_FAST_START_TEMP_FILE, + G_PARAM_READWRITE | G_PARAM_CONSTRUCT)); gstelement_class->request_new_pad = GST_DEBUG_FUNCPTR (gst_qt_mux_request_new_pad); @@ -434,6 +435,7 @@ gst_qt_mux_add_mp4_date (GstQTMux * qtmux, const GstTagList * list, GST_DEBUG_OBJECT (qtmux, "Adding tag %" GST_FOURCC_FORMAT " -> %s", GST_FOURCC_ARGS (fourcc), str); atom_moov_add_str_tag (qtmux->moov, fourcc, str); + g_free (str); } static void