Delay queue fixes --- should be academic.

This commit is contained in:
Christian Speckner 2016-11-23 23:55:10 +01:00
parent d02c985a91
commit cac9bf76c7
2 changed files with 3 additions and 1 deletions

View File

@ -57,6 +57,8 @@ void DelayQueue::reset()
{
for (DelayQueueMember& member : myMembers)
member.clear();
memset(myIndices, 0xFF, 0xFF);
}
} // namespace TIA6502tsCore

View File

@ -52,7 +52,7 @@ class DelayQueueMember
}
vector<Entry>::const_iterator end() const {
return (mySize < myEntries.size() - 1) ? (myEntries.begin() + mySize) : myEntries.end();
return (mySize < myEntries.size()) ? (myEntries.begin() + mySize) : myEntries.end();
}
void clear() {