Unlock the eventreader before calling handleEvent()
authorLars Knoll <lars.knoll@nokia.com>
Thu, 22 Sep 2011 14:50:13 +0000 (16:50 +0200)
committerQt by Nokia <qt-info@nokia.com>
Wed, 28 Sep 2011 01:16:56 +0000 (03:16 +0200)
Handle event can cause accesses to the event queue from
other places (e.g. through checkEvent()). Unlock the
reader to avoid deadlocks.

Change-Id: I1e5a79ce556920127848fccc3387d711c7cd32c2
Reviewed-on: http://codereview.qt-project.org/5557
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
src/plugins/platforms/xcb/qxcbconnection.cpp

index a0b8946..f7642fa 100644 (file)
@@ -634,7 +634,9 @@ void QXcbConnection::processXcbEvents()
                 else
                     ++it;
             }
+            m_reader->unlock();
             handleXcbEvent(event);
+            m_reader->lock();
         }
 
         free(event);