[vlc-devel] [PATCH] hds: Ignore sentinel value at the end of the fragment table
Antti Ajanki
antti.ajanki at iki.fi
Mon Oct 6 19:12:57 CEST 2014
generate_new_chunk() never proceed to the last fragment run if the
sentinel is included.
---
modules/stream_filter/hds/hds.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/modules/stream_filter/hds/hds.c b/modules/stream_filter/hds/hds.c
index ff7d7a6..1831d71 100644
--- a/modules/stream_filter/hds/hds.c
+++ b/modules/stream_filter/hds/hds.c
@@ -430,6 +430,15 @@ static uint8_t* parse_afrt( vlc_object_t* p_this,
s->fragment_run_count++;
}
+ if ( s->fragment_runs[s->fragment_run_count-1].fragment_number_start == 0 &&
+ s->fragment_runs[s->fragment_run_count-1].fragment_timestamp == 0 &&
+ s->fragment_runs[s->fragment_run_count-1].fragment_duration == 0 &&
+ s->fragment_runs[s->fragment_run_count-1].discont == 0 )
+ {
+ /* ignore sentinel value */
+ s->fragment_run_count--;
+ }
+
return data_p;
}
--
1.7.10.4
More information about the vlc-devel
mailing list