From dec880031d16f1ee4919a36f49298419246cf6a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= <sebastian@centricular.com> Date: Mon, 30 Jan 2017 15:39:59 +0200 Subject: asfdemux: Reset number of languages to 0 when freeing the array because of errors Otherwise we will happily index into the array at NULL if the requested index is smaller than the number of languages that were previously allocated. https://bugzilla.gnome.org/show_bug.cgi?id=777937 diff --git a/gst/asfdemux/gstasfdemux.c b/gst/asfdemux/gstasfdemux.c index ea5158f..255a427 100644 --- a/gst/asfdemux/gstasfdemux.c +++ b/gst/asfdemux/gstasfdemux.c @@ -3962,6 +3962,7 @@ not_enough_data: GST_WARNING_OBJECT (demux, "short read parsing language list object!"); g_free (demux->languages); demux->languages = NULL; + demux->num_languages = 0; return GST_FLOW_OK; /* not fatal */ } } -- cgit v0.10.2