Fix typo in QMutex's free-list's Sizes[3]
A QFreeList's MaxIndex is clearly meant to be the sum of its Sizes; but the parentheses in MaxIndex - (16 - 128 - 1024) doesn't give the same as without the parentheses. Noticed while reviewing a copy of this code now used by QReadWriteLock (which has this fix). Change-Id: I9f68171475b3c6edc18896056b5532183fee92b2 Reviewed-by: Sean Harmer <sean.harmer@kdab.com> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This commit is contained in:
parent
2ea90c56f2
commit
d3e73b4f6b
@ -642,7 +642,7 @@ const int FreeListConstants::Sizes[FreeListConstants::BlockCount] = {
|
|||||||
16,
|
16,
|
||||||
128,
|
128,
|
||||||
1024,
|
1024,
|
||||||
FreeListConstants::MaxIndex - (16-128-1024)
|
FreeListConstants::MaxIndex - (16 + 128 + 1024)
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef QFreeList<QMutexPrivate, FreeListConstants> FreeList;
|
typedef QFreeList<QMutexPrivate, FreeListConstants> FreeList;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user