Make sure not to reload an old rr stream chunk when reaching the end of a file

This commit is contained in:
Jeffrey Pfau 2014-07-29 23:39:55 -07:00
parent e3410fc457
commit 9cc97410d3
1 changed files with 1 additions and 0 deletions

View File

@ -263,6 +263,7 @@ bool _seekTag(struct GBARRContext* rr, struct VFile* vf, enum GBARRTag tag) {
enum GBARRTag readTag;
while ((readTag = _readTag(rr, vf)) != tag) {
if (readTag == TAG_END) {
rr->nextTime = 0;
while (_readTag(rr, vf) != TAG_EOF);
if (!rr->nextTime || !GBARRLoadStream(rr, rr->nextTime)) {
return false;