summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authorThiago Santos <thiago.sousa.santos@collabora.com>2013-07-01 14:35:02 -0300
committerThiago Santos <thiago.sousa.santos@collabora.com>2013-07-01 14:35:02 -0300
commitd9c324c6c7c1dcbce2e3c43be8d0c02629d88ed0 (patch)
treeb7dd8ae085d6099e5ccdbc0b38a66e98ab519ea1 /ext
parentd0befd39f0d63d6ec4bcb2fd651af14a4d3dbcf1 (diff)
downloadgstreamer-plugins-bad-d9c324c6c7c1dcbce2e3c43be8d0c02629d88ed0.tar.gz
dashdemux: prevent crash by checking if the segment node is present
Do not try to access range data if there is no segment node
Diffstat (limited to 'ext')
-rw-r--r--ext/dash/gstmpdparser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/dash/gstmpdparser.c b/ext/dash/gstmpdparser.c
index 9ab4dd563..aa17910ab 100644
--- a/ext/dash/gstmpdparser.c
+++ b/ext/dash/gstmpdparser.c
@@ -3319,7 +3319,7 @@ gst_mpd_client_get_next_fragment (GstMpdClient * client,
*discontinuity = segment_idx != currentChunk->number;
*range_start = 0;
*range_end = -1;
- if (currentChunk->SegmentURL->mediaRange) {
+ if (currentChunk->SegmentURL && currentChunk->SegmentURL->mediaRange) {
*range_start = currentChunk->SegmentURL->mediaRange->first_byte_pos;
*range_end = currentChunk->SegmentURL->mediaRange->last_byte_pos;
}