1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-25 07:43:54 +02:00

Fix ASSERT condition.

I introduced this overly zealous ASSERT during a recent clean up.
This commit is contained in:
James Crook
2017-12-14 16:27:44 +00:00
parent cab984d590
commit 970b9a27ee

View File

@@ -134,7 +134,8 @@ void MeterUpdateQueue::Clear()
// queue was full.
bool MeterUpdateQueue::Put(MeterUpdateMsg &msg)
{
wxASSERT( mEnd >= mStart);
// mStart cnan be greater than mEnd because it is all mod mBufferSize
wxASSERT( (mEnd + mBufferSize - mStart) >= 0 );
int len = (mEnd + mBufferSize - mStart) % mBufferSize;
// Never completely fill the queue, because then the