ext/ffmpeg/: fix memleaks

Original commit message from CVS:
* ext/ffmpeg/gstffmpegdec.c: (gst_ffmpegdec_register):
* ext/ffmpeg/gstffmpegdemux.c: (gst_ffmpegdemux_register):
fix memleaks
This commit is contained in:
Benjamin Otte 2004-04-06 18:25:55 +00:00
parent 825e3102bd
commit 50a9ae3608
3 changed files with 12 additions and 1 deletions

View file

@ -1,3 +1,9 @@
2004-04-06 Benjamin Otte <otte@gnome.org>
* ext/ffmpeg/gstffmpegdec.c: (gst_ffmpegdec_register):
* ext/ffmpeg/gstffmpegdemux.c: (gst_ffmpegdemux_register):
fix memleaks
2004-04-05 Benjamin Otte <otte@gnome.org>
* configure.ac:

View file

@ -495,8 +495,11 @@ gst_ffmpegdec_register (GstPlugin * plugin)
/* first make sure we've got a supported type */
sinkcaps = gst_ffmpeg_codecid_to_caps (in_plugin->id, NULL, FALSE);
srccaps = gst_ffmpeg_codectype_to_caps (in_plugin->type, NULL);
if (!sinkcaps || !srccaps)
if (!sinkcaps || !srccaps) {
if (sinkcaps) gst_caps_free (sinkcaps);
if (srccaps) gst_caps_free (srccaps);
goto next;
}
/* construct the type */
type_name = g_strdup_printf ("ffdec_%s", in_plugin->name);

View file

@ -744,6 +744,8 @@ gst_ffmpegdemux_register (GstPlugin * plugin)
!gst_type_find_register (plugin, typefind_name, GST_RANK_MARGINAL,
gst_ffmpegdemux_type_find, extensions, sinkcaps, params)) {
g_warning ("Register of type ffdemux_%s failed", name);
g_free (type_name);
g_free (typefind_name);
return FALSE;
}