mirror of
https://github.com/qgis/QGIS.git
synced 2025-03-10 00:13:55 -04:00
Be on the safe side, check for null message bar pointer
This commit is contained in:
parent
74c4f8e3f3
commit
0fcba4ed11
@ -407,7 +407,7 @@ void myMessageOutput( QtMsgType type, const char *msg )
|
||||
dumpBacktrace( 20 );
|
||||
|
||||
// also be super obnoxious -- we DON'T want to allow these errors to be ignored!!
|
||||
if ( QgisApp::instance() && QgisApp::instance()->thread() == QThread::currentThread() )
|
||||
if ( QgisApp::instance() && QgisApp::instance()->messageBar() && QgisApp::instance()->thread() == QThread::currentThread() )
|
||||
{
|
||||
QgisApp::instance()->messageBar()->pushCritical( QStringLiteral( "Qt" ), msg );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user