[vlc-commits] demux: adaptive: flag eof on failed buffered chunks
Francois Cartegnie
git at videolan.org
Fri Apr 15 10:58:05 CEST 2016
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Fri Apr 15 10:55:07 2016 +0200| [e88d9b0e37d761fbf7971a45ac639acc831b7bc4] | committer: Francois Cartegnie
demux: adaptive: flag eof on failed buffered chunks
Otherwise keeps trying over all other segments
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=e88d9b0e37d761fbf7971a45ac639acc831b7bc4
---
modules/demux/adaptive/http/Chunk.cpp | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/modules/demux/adaptive/http/Chunk.cpp b/modules/demux/adaptive/http/Chunk.cpp
index 21eeec7..f055125 100644
--- a/modules/demux/adaptive/http/Chunk.cpp
+++ b/modules/demux/adaptive/http/Chunk.cpp
@@ -270,6 +270,7 @@ void HTTPChunkBufferedSource::bufferize(size_t readsize)
if(!prepare())
{
done = true;
+ eof = true;
vlc_cond_signal(&avail);
vlc_mutex_unlock(&lock);
return;
@@ -285,7 +286,10 @@ void HTTPChunkBufferedSource::bufferize(size_t readsize)
block_t *p_block = block_Alloc(readsize);
if(!p_block)
+ {
+ eof = true;
return;
+ }
struct
{
@@ -299,6 +303,7 @@ void HTTPChunkBufferedSource::bufferize(size_t readsize)
block_Release(p_block);
vlc_mutex_lock(&lock);
done = true;
+ eof = true;
rate.size = buffered + consumed;
rate.time = mdate() - downloadstart;
downloadstart = 0;
@@ -313,6 +318,7 @@ void HTTPChunkBufferedSource::bufferize(size_t readsize)
if((size_t) ret < readsize)
{
done = true;
+ eof = true;
rate.size = buffered + consumed;
rate.time = mdate() - downloadstart;
downloadstart = 0;
More information about the vlc-commits
mailing list