Skip to content

Commit addcf3c

Browse files
m-kuhnjef-n
authored andcommittedMar 23, 2016
Don't crash when some shortcuts can't be loaded
Fix #14528 (cherry picked from commit 76296c8)
1 parent 0c65f7f commit addcf3c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed
 

‎src/app/qgsconfigureshortcutsdialog.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,8 @@ void QgsConfigureShortcutsDialog::loadShortcuts()
224224
actionName = child.attribute( "name" );
225225
actionShortcut = child.attribute( "shortcut" );
226226
action = QgsShortcutsManager::instance()->actionByName( actionName );
227-
QgsShortcutsManager::instance()->setActionShortcut( action, actionShortcut );
227+
if ( action )
228+
QgsShortcutsManager::instance()->setActionShortcut( action, actionShortcut );
228229
child = child.nextSiblingElement();
229230
}
230231

0 commit comments

Comments
 (0)
Please sign in to comment.