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

Unplugging the external screen attached to a closed MacBookPro, causes all running Qt applications to crash

    XMLWordPrintable

Details

    Description

      Description

      When you unplug the external screen attached to a closed MacBookPro, all running Qt applications are crashing.

       

      Reproducibility

      • This issue is reproducible with Qt 5.13.1 on macOS 10.15.1

       

      Steps to reproduce

      1. Attach an external display to a MacBook Pro. I used a Thunderbolt Dock and Display Port to connect the external display.
      2. Close the MacBook Pro
      3. Launch any Qt application on the external screen. For example Qt Creator or Linguist.app.
      4. Unplug the Thunderbold cable of the external display
      5. Open the lid after having unplugged the cable and with the cable still unplugged

      Result: All running Qt applications (for example Qt Creator or Linguist.app) have crashed

       

       

      More info

       The crash occurs in windowWillUseStandardFrame:defaultFrame: in qnswindowdelegate.mm.

      As you can see in this code, there is no check for NULL pointer for platformWindow->screen() which is I think causing the crash:

          const QRectF screenGeometry = platformWindow->screen()->geometry();

       

      Qt Support:

      Tested the steps to reproduce with similar equipment. Could not reproduce the issue. We suspect that some setting or other unknown is causing this.

      Attachments

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

        Activity

          People

            vestbo Tor Arne Vestbø
            timaccorsair Alexandre Colucci
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes