adaptivedemux: Avoid using unset GError
authorEdward Hervey <edward@centricular.com>
Mon, 12 Dec 2016 14:09:36 +0000 (15:09 +0100)
committerEdward Hervey <bilboed@bilboed.com>
Mon, 12 Dec 2016 15:05:38 +0000 (16:05 +0100)
gst_uri_handler_set_uri() doesn't guarantee the GError will be set
if it returns FALSE.

gst-libs/gst/adaptivedemux/gstadaptivedemux.c

index bf311d3ab9d9e05bf7caadef08c1ba5fea82a7c8..1a307c866204a9ec4eccdb7cdc21caf963999508 100644 (file)
@@ -2507,7 +2507,7 @@ gst_adaptive_demux_stream_update_source (GstAdaptiveDemuxStream * stream,
 
         stream->src = NULL;
         GST_DEBUG_OBJECT (demux, "Failed to re-use old source element: %s",
-            err->message);
+            err ? err->message : "Unknown error");
         g_clear_error (&err);
         gst_object_unref (stream->src_srcpad);
         stream->src_srcpad = NULL;