mirror of
https://github.com/tildearrow/furnace.git
synced 2024-11-01 10:32:40 +00:00
FixedQueue: and again
This commit is contained in:
parent
2f9d1d3eef
commit
d69cdedd4a
1 changed files with 1 additions and 1 deletions
|
@ -76,7 +76,7 @@ template <typename T, size_t items> bool FixedQueue<T,items>::erase(size_t pos)
|
|||
return pop_back();
|
||||
}
|
||||
|
||||
for (size_t i=pos, p=(readPos+pos)%items, p1=(readPos+pos+1)%items; i<=curSize; i++) {
|
||||
for (size_t i=pos+1, p=(readPos+pos)%items, p1=(readPos+pos+1)%items; i<curSize; i++) {
|
||||
if (p>=items) p-=items;
|
||||
if (p1>=items) p1-=items;
|
||||
data[p]=data[p1];
|
||||
|
|
Loading…
Reference in a new issue