From 81b7ab9a0e319fd62de5af85e631375504209140 Mon Sep 17 00:00:00 2001 From: Thulinma Date: Wed, 4 Mar 2015 18:58:08 +0100 Subject: [PATCH] Fix page switching right after an audio track seek. --- src/output/output.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/output/output.cpp b/src/output/output.cpp index 59b12db7..7febf738 100644 --- a/src/output/output.cpp +++ b/src/output/output.cpp @@ -597,6 +597,7 @@ namespace Mist { DEBUG_MSG(DLVL_DONTEVEN, "Loading track %u (next=%lu), %llu ms", nxt.tid, nxtKeyNum[nxt.tid], nxt.time); if (nxt.offset >= curPages[nxt.tid].len){ + nxtKeyNum[nxt.tid] = getKeyForTime(nxt.tid, currentPacket.getTime()); loadPageForKey(nxt.tid, ++nxtKeyNum[nxt.tid]); nxt.offset = 0; if (curPages.count(nxt.tid) && curPages[nxt.tid].mapped){ @@ -644,6 +645,7 @@ namespace Mist { updateMeta(); }else{ //if we're not live, we've simply reached the end of the page. Load the next key. + nxtKeyNum[nxt.tid] = getKeyForTime(nxt.tid, currentPacket.getTime()); loadPageForKey(nxt.tid, ++nxtKeyNum[nxt.tid]); nxt.offset = 0; if (curPages.count(nxt.tid) && curPages[nxt.tid].mapped){