Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-37233

Crash in QPaintEngine::syncState() EXC_BAS_ACCESS on OSX 10.9.2

    XMLWordPrintable

Details

    • Bug
    • Resolution: Incomplete
    • P2: Important
    • None
    • 5.2.1
    • None
    • iMac
      OS X 10.9.1
      Xcode Version 5.0.2 (5A3005)
      Qt 5.2.1 Open source version
      CMake 2.8.12.1
    • macOS

    Description

      See the attached image. I have a MainWindow with DockWidgets around the edge and an OpenGL widget in the centre. The right hand DockWidget has an instance of QtPropertyBrowser (up to date with the repository). The Application is a Level Editor for a video game.

      If I load a simple scene, start to edit a property within the propertybrowser (see on the right how rot->x has focus) and then press the play button on the toolbar I get a crash. If no widget is being edited the crash does to occur. The crash is not reproducible in Windows 7.

      Xcode has captured the following warning in std::out:

      QWidget::repaint: Recursive repaint detected
      QWidget::paintEngine: Should no longer be called
      QPainter::begin: Paint device returned engine == 0, type: 1

      None of my code calls 'repaint', only 'update' is called. PropertyBrowser doesn't seem to call repaint either.

      Xcode does not display a full stack in it's UI however issuing 'bt' to lldb shows:
      (lldb) bt

      • thread #1: tid = 0xd098f, 0x00000000010f92b0 QtGui_debug`QPaintEngine::syncState() + 16, queue = 'com.apple.main-thread, stop reason = EXC_BAD_ACCESS (code=1, address=0x8)
        frame #0: 0x00000000010f92b0 QtGui_debug`QPaintEngine::syncState() + 16
        frame #1: 0x000000000004b0f4 QtWidgets_debug`(anonymous namespace)::QMacCGContext::QMacCGContext(QPainter*) + 52
        frame #2: 0x0000000000025e8d QtWidgets_debug`(anonymous namespace)::QMacCGContext::QMacCGContext(QPainter*) + 29
        frame #3: 0x00000000000313c4 QtWidgets_debug`QMacStyle::drawControl(QStyle::ControlElement, QStyleOption const*, QPainter*, QWidget const*) const + 100
        frame #4: 0x000000000021f9bd QtWidgets_debug`QFrame::drawFrame(QPainter*) + 445
        frame #5: 0x000000000021f7e6 QtWidgets_debug`QFrame::paintEvent(QPaintEvent*) + 70
        frame #6: 0x00000000002d4f22 QtWidgets_debug`QAbstractScrollArea::event(QEvent*) + 1298
        frame #7: 0x000000000038a012 QtWidgets_debug`QAbstractItemView::event(QEvent*) + 546
        frame #8: 0x0000000000429a0c QtWidgets_debug`QTreeWidget::event(QEvent*) + 92
        frame #9: 0x000000000006b76f QtWidgets_debug`QApplicationPrivate::notify_helper(QObject*, QEvent*) + 399
        frame #10: 0x0000000000070ab2 QtWidgets_debug`QApplication::notify(QObject*, QEvent*) + 15442
        frame #11: 0x0000000001c2943f QtCore_debug`QCoreApplication::notifyInternal(QObject*, QEvent*) + 207
        frame #12: 0x00000000000748ef QtWidgets_debug`QCoreApplication::sendSpontaneousEvent(QObject*, QEvent*) + 95
        frame #13: 0x00000000000c0784 QtWidgets_debug`QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 2404
        frame #14: 0x00000000000c1277 QtWidgets_debug`QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 1495
        frame #15: 0x00000000000c0c64 QtWidgets_debug`QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 3652
        frame #16: 0x00000000000c1277 QtWidgets_debug`QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 1495
        frame #17: 0x00000000000c10ca QtWidgets_debug`QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 1066
        frame #18: 0x00000000000c10ca QtWidgets_debug`QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 1066
        frame #19: 0x00000000000c0c64 QtWidgets_debug`QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 3652
        frame #20: 0x00000000000c1277 QtWidgets_debug`QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 1495
        frame #21: 0x00000000000c0c64 QtWidgets_debug`QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 3652
        frame #22: 0x00000000000c1277 QtWidgets_debug`QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 1495
        frame #23: 0x00000000000c10ca QtWidgets_debug`QWidgetPrivate::paintSiblingsRecursive(QPaintDevice*, QList<QObject*> const&, int, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 1066
        frame #24: 0x00000000000c0c64 QtWidgets_debug`QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) + 3652
        frame #25: 0x000000000008255c QtWidgets_debug`QWidgetBackingStore::sync() + 4140
        frame #26: 0x00000000000b6366 QtWidgets_debug`QWidgetPrivate::syncBackingStore() + 150
        frame #27: 0x00000000000c84a3 QtWidgets_debug`QWidget::event(QEvent*) + 4099
        frame #28: 0x0000000000240ff3 QtWidgets_debug`QMainWindow::event(QEvent*) + 2003
        frame #29: 0x000000000006b76f QtWidgets_debug`QApplicationPrivate::notify_helper(QObject*, QEvent*) + 399
        frame #30: 0x0000000000070ab2 QtWidgets_debug`QApplication::notify(QObject*, QEvent*) + 15442
        frame #31: 0x0000000001c2943f QtCore_debug`QCoreApplication::notifyInternal(QObject*, QEvent*) + 207
        frame #32: 0x000000000004c4ea QtWidgets_debug`QCoreApplication::sendEvent(QObject*, QEvent*) + 90
        frame #33: 0x000000000007f23c QtWidgets_debug`sendUpdateRequest(QWidget*, bool) + 76
        frame #34: 0x000000000007f858 QtWidgets_debug`QWidgetBackingStore::markDirty(QRect const&, QWidget*, bool, bool) + 1480
        frame #35: 0x00000000000cac1a QtWidgets_debug`QWidget::repaint(QRect const&) + 330
        frame #36: 0x00000000000caac5 QtWidgets_debug`QWidget::repaint() + 53
        frame #37: 0x00000000001b7336 QtWidgets_debug`QAbstractButtonPrivate::click() + 342
        frame #38: 0x00000000001b86ef QtWidgets_debug`QAbstractButton::mouseReleaseEvent(QMouseEvent*) + 239
        frame #39: 0x00000000002d0614 QtWidgets_debug`QToolButton::mouseReleaseEvent(QMouseEvent*) + 52
        frame #40: 0x00000000000c7780 QtWidgets_debug`QWidget::event(QEvent*) + 736
        frame #41: 0x00000000001b84f1 QtWidgets_debug`QAbstractButton::event(QEvent*) + 449
        frame #42: 0x00000000002d0c39 QtWidgets_debug`QToolButton::event(QEvent*) + 153
        frame #43: 0x000000000006b76f QtWidgets_debug`QApplicationPrivate::notify_helper(QObject*, QEvent*) + 399
        frame #44: 0x000000000006e17b QtWidgets_debug`QApplication::notify(QObject*, QEvent*) + 4891
        frame #45: 0x0000000001c2943f QtCore_debug`QCoreApplication::notifyInternal(QObject*, QEvent*) + 207
        frame #46: 0x00000000000748ef QtWidgets_debug`QCoreApplication::sendSpontaneousEvent(QObject*, QEvent*) + 95
        frame #47: 0x000000000006c58f QtWidgets_debug`QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) + 1119
        frame #48: 0x00000000000f8782 QtWidgets_debug`QWidgetWindow::handleMouseEvent(QMouseEvent*) + 3138
        frame #49: 0x00000000000f736f QtWidgets_debug`QWidgetWindow::event(QEvent*) + 895
        frame #50: 0x000000000006b76f QtWidgets_debug`QApplicationPrivate::notify_helper(QObject*, QEvent*) + 399
        frame #51: 0x000000000006d65f QtWidgets_debug`QApplication::notify(QObject*, QEvent*) + 2047
        frame #52: 0x0000000001c2943f QtCore_debug`QCoreApplication::notifyInternal(QObject*, QEvent*) + 207
        frame #53: 0x0000000000e7a00f QtGui_debug`QCoreApplication::sendSpontaneousEvent(QObject*, QEvent*) + 95
        frame #54: 0x0000000000e724a4 QtGui_debug`QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) + 1780
        frame #55: 0x0000000000e71a6e QtGui_debug`QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) + 142
        frame #56: 0x0000000000e5793d QtGui_debug`QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) + 141
        frame #57: 0x000000000392d7f8 libqcocoa_debug.dylib`QCocoaEventDispatcherPrivate::processPostedEvents() + 296
        frame #58: 0x000000000392e5e8 libqcocoa_debug.dylib`QCocoaEventDispatcherPrivate::postedEventsSourceCallback(void*) + 88
        frame #59: 0x00007fff918e9731 CoreFoundation`_CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION_ + 17
        frame #60: 0x00007fff918daea2 CoreFoundation`__CFRunLoopDoSources0 + 242
        frame #61: 0x00007fff918da62f CoreFoundation`__CFRunLoopRun + 831
        frame #62: 0x00007fff918da0b5 CoreFoundation`CFRunLoopRunSpecific + 309
        frame #63: 0x00007fff8da69a0d HIToolbox`RunCurrentEventLoopInMode + 226
        frame #64: 0x00007fff8da69685 HIToolbox`ReceiveNextEventCommon + 173
        frame #65: 0x00007fff8da695bc HIToolbox`_BlockUntilNextEventMatchingListInModeWithFilter + 65
        frame #66: 0x00007fff93acd3de AppKit`_DPSNextEvent + 1434
        frame #67: 0x00007fff93acca2b AppKit`-[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 122
        frame #68: 0x00007fff93ac0b2c AppKit`-[NSApplication run] + 553
        frame #69: 0x000000000392c7f1 libqcocoa_debug.dylib`QCocoaEventDispatcher::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) + 1137
        frame #70: 0x0000000001c249aa QtCore_debug`QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) + 122
        frame #71: 0x0000000001c24bec QtCore_debug`QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) + 556
        frame #72: 0x0000000001c29c12 QtCore_debug`QCoreApplication::exec() + 386
        frame #73: 0x0000000000e71686 QtGui_debug`QGuiApplication::exec() + 22
        frame #74: 0x000000000006cd39 QtWidgets_debug`QApplication::exec() + 9
        frame #75: 0x0000000100010570 BSEd`main(argc=1, argv=0x00007fff5fbff060) + 384 at main.cpp:25
        frame #76: 0x00007fff8c1ba5fd libdyld.dylib`start + 1

      I can make the source to my editor available for testing.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            sorvig Morten Sørvig
            djr djr
            Votes:
            2 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes