diff --git a/gst/matroska/matroska-demux.c b/gst/matroska/matroska-demux.c index 756aa67efe..ad0670fa33 100644 --- a/gst/matroska/matroska-demux.c +++ b/gst/matroska/matroska-demux.c @@ -1123,9 +1123,7 @@ gst_matroska_demux_add_stream (GstMatroskaDemux * demux, GstEbmlRead * ebml) demux->common.num_streams--; g_ptr_array_remove_index (demux->common.src, demux->common.num_streams); g_assert (demux->common.src->len == demux->common.num_streams); - if (context) { - gst_matroska_track_free (context); - } + gst_matroska_track_free (context); return ret; } diff --git a/gst/matroska/matroska-parse.c b/gst/matroska/matroska-parse.c index 53b4eaca72..11de18b503 100644 --- a/gst/matroska/matroska-parse.c +++ b/gst/matroska/matroska-parse.c @@ -940,9 +940,7 @@ gst_matroska_parse_add_stream (GstMatroskaParse * parse, GstEbmlRead * ebml) parse->common.num_streams--; g_ptr_array_remove_index (parse->common.src, parse->common.num_streams); g_assert (parse->common.src->len == parse->common.num_streams); - if (context) { - gst_matroska_track_free (context); - } + gst_matroska_track_free (context); return ret; }