diff -r 69409653e863 -r dd05fdd05078 uiacceltk/hitchcock/plugins/alfoogmplugin/src/alfoogmplugin.cpp --- a/uiacceltk/hitchcock/plugins/alfoogmplugin/src/alfoogmplugin.cpp Tue Jun 22 12:40:35 2010 +0300 +++ b/uiacceltk/hitchcock/plugins/alfoogmplugin/src/alfoogmplugin.cpp Tue Jul 06 14:56:00 2010 +0300 @@ -90,10 +90,16 @@ // TAny* CreatePlugin() { - CAlfOogmMonitorPlugin* plugin = new(ELeave) CAlfOogmMonitorPlugin; - CleanupStack::PushL(plugin); - plugin->ConstructL(); - CleanupStack::Pop(plugin); + CAlfOogmMonitorPlugin* plugin = new CAlfOogmMonitorPlugin; + if ( plugin ) + { + TRAPD( err, plugin->ConstructL() ); + if ( err != KErrNone ) + { + delete plugin; + plugin = NULL; + } + } return plugin; }