Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
5.12.1, 5.14.0
-
IOS 12.1.4, 12.2, 1.3
-
-
d829d54a42393d797c5f6ab3b80e88df35fad1e4 (qt/qtbase/dev) 51838c964f9e6e62a30a6b5875302b9a8a1c4713 (qt/qtbase/6.1) 697c4b8f491ddc91c3275c604cffa26f226c0001 (qt/tqtc-qtbase/5.15) 5bdb2c8863492316e4fb041ba1f123f1e062048c (qt/qtbase/6.2)
Description
After an external screen is disconnected and application returns from the background it crashes. Also happened with QT sample applications.
Looks like Qt creates ViewController for the external screen and then tries to access it, but the screen has already been destroyed by OS.
EXC_BAD_ACCESSQtPrivate::QFunctorSlotObject<-[QIOSViewController
initWithQIOSScreen:]::$_1, 2, QtPrivate::List<Qt::ApplicationState,
Qt::ApplicationState>, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*
Attempted to dereference garbage pointer 0x500640078
Stack trace (from Bugsnag):
QtPrivate::QFunctorSlotObject<-[QIOSViewController initWithQIOSScreen:]::$_1, 2, QtPrivate::List<Qt::ApplicationState, Qt::ApplicationState>, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*, void**, bool*) QMetaObject::activate(QObject*, int, int, void**) QIOSApplicationState::handleApplicationStateChanged(UIApplicationState, QString const&) ___ZL38qRegisterApplicationStateNotificationsv_block_invoke qt_main_wrapper
Steps to reproduce:
1. Connect device to HDMI / Airplay / Or Mac recording
2. Start application
3. Go to background
4. Disconnect second screen
5. Return to foreground