Skip to content
Permalink
Browse files

Fix Coverity null-pointer dererence warnings

  • Loading branch information
nyalldawson committed Apr 3, 2018
1 parent c2af8ca commit 7b0cf28ecbe74e59a512d3a7cea8caac32ec1a40
Showing with 6 additions and 2 deletions.
  1. +6 −2 src/app/qgsoptions.cpp
@@ -834,9 +834,10 @@ QgsOptions::QgsOptions( QWidget *parent, Qt::WindowFlags fl, const QList<QgsOpti

QgsColorScheme *scheme = QgsApplication::colorSchemeRegistry()->schemes().value( index );
if ( scheme )
{
mTreeCustomColors->setScheme( scheme );

updateActionsForCurrentColorScheme( scheme );
updateActionsForCurrentColorScheme( scheme );
}
} );

//
@@ -2336,6 +2337,9 @@ void QgsOptions::refreshSchemeComboBox()

void QgsOptions::updateActionsForCurrentColorScheme( QgsColorScheme *scheme )
{
if ( !scheme )
return;

mButtonImportColors->setEnabled( scheme->isEditable() );
mButtonPasteColors->setEnabled( scheme->isEditable() );
mButtonAddColor->setEnabled( scheme->isEditable() );

0 comments on commit 7b0cf28

Please sign in to comment.
You can’t perform that action at this time.