From 31eb731cab2c6a582a42d35f90ca23f676e313e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Thu, 5 Jul 2012 18:58:33 +0200 Subject: [PATCH] Fix potential crash if no any plugins present Thanks to Roman Savochenko for the patch! --- kbfxlib/data/kbfxplasmapluginloader.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kbfxlib/data/kbfxplasmapluginloader.cpp b/kbfxlib/data/kbfxplasmapluginloader.cpp index ed2c458..0258ca7 100644 --- a/kbfxlib/data/kbfxplasmapluginloader.cpp +++ b/kbfxlib/data/kbfxplasmapluginloader.cpp @@ -103,7 +103,7 @@ KbfxPlasmaPluginLoader::getView ( TQString name ) pluginMap().remove ( it ); } init(); - KbfxDataStack * stack = pluginMap() [name]->data(); + KbfxDataStack * stack = pluginMap() [name] ? pluginMap() [name]->data() : NULL; if (stack == 0 ) { return new KbfxDataStack();