mpdparser: Don't crash in debug output if stream->segments is NULL
authorSebastian Dröge <sebastian@centricular.com>
Thu, 4 Jun 2015 13:57:57 +0000 (15:57 +0200)
committerSebastian Dröge <sebastian@centricular.com>
Thu, 4 Jun 2015 13:58:46 +0000 (15:58 +0200)
ext/dash/gstmpdparser.c

index 6f3927565bdecb5aed882856035a7edb9febe461..dcd24da3f5cdd272d3317b4fd4c3f8d588526614 100644 (file)
@@ -3965,7 +3965,7 @@ gst_mpd_client_advance_segment (GstMpdClient * client, GstActiveStream * stream,
 
 done:
   GST_DEBUG ("Advanced to segment: %d / %d r:%d (ret: %s)",
-      stream->segment_index, stream->segments->len,
+      stream->segment_index, (stream->segments ? stream->segments->len : -1),
       stream->segment_repeat_index, gst_flow_get_name (ret));
   return ret;
 }