Commit 4c8449c8 authored by Don Gagne's avatar Don Gagne

Fix crash after last UAS is removed

ui->waitingLabel is deleted and set to NULL when mode is PX4. Must
check for NULL before using it.
parent ee3dfc6a
......@@ -95,9 +95,11 @@ void QGCConfigView::activeUASChanged(UASInterface* uas)
}
}
else {
//restore waiting label if we no longer have a connection
ui->gridLayout->addWidget(ui->waitingLabel);
ui->waitingLabel->setVisible(true);
if (ui->waitingLabel) {
//restore waiting label if we no longer have a connection
ui->gridLayout->addWidget(ui->waitingLabel);
ui->waitingLabel->setVisible(true);
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment