Avoid NULL-pointer deref

Change-Id: I49115befb18c5342b96c5561882dcdfa45772f22
Reviewed-by: Jarek Kobus <jaroslaw.kobus@nokia.com>
This commit is contained in:
Robert Loehning
2012-07-26 16:46:23 +02:00
committed by Jarek Kobus
parent 12a99d476c
commit 21cf52aeea

View File

@@ -286,9 +286,10 @@ void CodeStyleSelectorWidget::slotCopyClicked()
if (!ok)
return;
ICodeStylePreferences *copy = codeStylePool->cloneCodeStyle(currentPreferences);
if (copy) {
copy->setDisplayName(newName);
if (copy)
m_codeStyle->setCurrentDelegate(copy);
}
}
void CodeStyleSelectorWidget::slotEditClicked()