[vlc-commits] demux: adaptive: use current segment number when available
Francois Cartegnie
git at videolan.org
Mon May 18 20:58:52 CEST 2020
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Mon May 18 17:56:46 2020 +0200| [a59a0690dce601b26ed205a6bb1cf408f745a007] | committer: Francois Cartegnie
demux: adaptive: use current segment number when available
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=a59a0690dce601b26ed205a6bb1cf408f745a007
---
modules/demux/adaptive/SegmentTracker.cpp | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/modules/demux/adaptive/SegmentTracker.cpp b/modules/demux/adaptive/SegmentTracker.cpp
index 8d6e4981fe..5a675481d7 100644
--- a/modules/demux/adaptive/SegmentTracker.cpp
+++ b/modules/demux/adaptive/SegmentTracker.cpp
@@ -389,7 +389,9 @@ vlc_tick_t SegmentTracker::getMinAheadTime() const
if(rep->needsUpdate())
(void) rep->runLocalUpdates(resources);
- uint64_t startnumber = bufferingLogic->getStartSegmentNumber(rep);
+ uint64_t startnumber = curNumber;
+ if(startnumber == std::numeric_limits<uint64_t>::max())
+ startnumber = bufferingLogic->getStartSegmentNumber(rep);
if(startnumber != std::numeric_limits<uint64_t>::max())
return rep->getMinAheadTime(startnumber);
}
More information about the vlc-commits
mailing list