summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTor Arne Vestbø <[email protected]>2019-01-22 16:30:44 +0100
committerTor Arne Vestbø <[email protected]>2019-01-29 11:06:28 +0000
commit775b5e26315f96b29840198a089f82edea52e1a1 (patch)
tree1d60cef71345196d24e23049dc777cbc4272b664
parentc2b0bca98429853bcd1f91dff5ae44742b48bc1f (diff)
Remove requirement to lock graphics buffer before getting total size
QPlatformGraphicsBuffer::byteCount() shouldn't need locking unless bytesPerLine() is implemented in a way that requires it, in which case the assert should be in the subclass. Change-Id: I0fdb04c0a3ab042408d6d17b2759509853573d16 Reviewed-by: Laszlo Agocs <[email protected]> Reviewed-by: Tor Arne Vestbø <[email protected]>
-rw-r--r--src/gui/kernel/qplatformgraphicsbuffer.cpp1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/gui/kernel/qplatformgraphicsbuffer.cpp b/src/gui/kernel/qplatformgraphicsbuffer.cpp
index cc01efd6db8..d361a8fc120 100644
--- a/src/gui/kernel/qplatformgraphicsbuffer.cpp
+++ b/src/gui/kernel/qplatformgraphicsbuffer.cpp
@@ -237,7 +237,6 @@ uchar *QPlatformGraphicsBuffer::data()
*/
int QPlatformGraphicsBuffer::byteCount() const
{
- Q_ASSERT(isLocked() & SWReadAccess);
return size().height() * bytesPerLine();
}