Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-85

Segfault due to desktop widget deletion

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P1: Critical
    • Resolution: Fixed
    • Affects Version/s: 1.2.x, 5.6, 5.9, dev
    • Fix Version/s: 5.6, 5.9, dev
    • Component/s: PySide

      Description

      Pyside will delete the widget returned by QApplication.desktop() if the .parent() method of the returned desktop widget has been called. Occurs because QApplication.desktop() sets the pyside parent to the application due to the set_qapp_parent_for_orphan injected code, but the .parent() call sets it to None because the C++ returned parent is NULL. This causes the hasOwnership C++ attribute of the wrapper to be set to true and a C++ delete call made when the ref count on the wrapper goes to 0.

      Other methods that use set_qapp_parent_for_orphan may have similar bugs.

        Attachments

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

          Activity

            People

            Assignee:
            ctismer Christian Tismer
            Reporter:
            jpe John Ehresman
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes