From 775b5e26315f96b29840198a089f82edea52e1a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Arne=20Vestb=C3=B8?= Date: Tue, 22 Jan 2019 16:30:44 +0100 Subject: Remove requirement to lock graphics buffer before getting total size MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Reviewed-by: Tor Arne Vestbø --- src/gui/kernel/qplatformgraphicsbuffer.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'src') diff --git a/src/gui/kernel/qplatformgraphicsbuffer.cpp b/src/gui/kernel/qplatformgraphicsbuffer.cpp index cc01efd6db..d361a8fc12 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(); } -- cgit v1.2.3