From 92e73cb6db92fe1ab69d76dc0fe8d1f4ab64d0d9 Mon Sep 17 00:00:00 2001 From: Thulinma Date: Fri, 30 Sep 2016 17:18:11 +0200 Subject: [PATCH] Fixed bug when tracks pause for 16 seconds. --- src/output/output.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/output/output.cpp b/src/output/output.cpp index eaa68dab..1daf8655 100644 --- a/src/output/output.cpp +++ b/src/output/output.cpp @@ -470,6 +470,7 @@ namespace Mist { nProxy.curPage[trackId].init(id, DEFAULT_DATA_PAGE_SIZE); if (!(nProxy.curPage[trackId].mapped)){ FAIL_MSG("Initializing page %s failed", nProxy.curPage[trackId].name.c_str()); + currKeyOpen.erase(trackId); return; } currKeyOpen[trackId] = pageNum; @@ -856,7 +857,7 @@ namespace Mist { } //if this is a live stream, we might have just reached the live point. //check where the next key is - nxtKeyNum[nxt.tid] = getKeyForTime(nxt.tid, thisPacket.getTime()); + nxtKeyNum[nxt.tid] = getKeyForTime(nxt.tid, nxt.time); int nextPage = pageNumForKey(nxt.tid, nxtKeyNum[nxt.tid]+1); //if the next key hasn't shown up on another page, then we're waiting. //VoD might be slow, so we check VoD case also, just in case