diff options
author | Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> | 2014-12-29 16:20:02 +0100 |
---|---|---|
committer | Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> | 2014-12-29 16:20:29 +0100 |
commit | f4bfdc5eed9f153f02f8370dc8bfa4aaea6de38c (patch) | |
tree | bd55c08da1d4c32ff16952b8ea5e3d96c19c5594 /src/client/qwaylandshmbackingstore.cpp | |
parent | 97091ce346cebac7f03a1a98c58d44d8d22edc2e (diff) | |
parent | 19f688dac38ba439dc5068fc6ad02dc271422702 (diff) |
Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
.qmake.conf
src/compositor/compositor_api/qwaylandsurface.cpp
Change-Id: I3ee40153c959dbe31ea685571c5a8bb1ae36606e
Diffstat (limited to 'src/client/qwaylandshmbackingstore.cpp')
-rw-r--r-- | src/client/qwaylandshmbackingstore.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/client/qwaylandshmbackingstore.cpp b/src/client/qwaylandshmbackingstore.cpp index 9ec800138..9bb36fdc7 100644 --- a/src/client/qwaylandshmbackingstore.cpp +++ b/src/client/qwaylandshmbackingstore.cpp @@ -46,6 +46,7 @@ #include <QtCore/qdebug.h> #include <QtGui/QPainter> +#include <QMutexLocker> #include <wayland-client.h> #include <unistd.h> @@ -185,6 +186,7 @@ void QWaylandShmBackingStore::endPaint() void QWaylandShmBackingStore::hidden() { + QMutexLocker lock(&mMutex); if (mFrameCallback) { wl_callback_destroy(mFrameCallback); mFrameCallback = Q_NULLPTR; @@ -347,6 +349,7 @@ void QWaylandShmBackingStore::done(void *data, wl_callback *callback, uint32_t t static_cast<QWaylandShmBackingStore *>(data); if (callback != self->mFrameCallback) // others, like QWaylandWindow, may trigger callbacks too return; + QMutexLocker lock(&self->mMutex); QWaylandWindow *window = self->waylandWindow(); wl_callback_destroy(self->mFrameCallback); self->mFrameCallback = 0; |