From 8c18c674f5ba691c53151595c30248dd9c824a33 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 6 Jun 2005 23:38:01 +0000 Subject: [PATCH] generate an error message when a module initialization fails, otherwise it's impossible to know why the program failed to start up git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@34558 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/module.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/common/module.cpp b/src/common/module.cpp index 5534c4c2dd..b5f5409cc6 100644 --- a/src/common/module.cpp +++ b/src/common/module.cpp @@ -69,8 +69,12 @@ bool wxModule::InitializeModules() wxModuleList::compatibility_iterator node; for ( node = m_modules.GetFirst(); node; node = node->GetNext() ) { - if ( !node->GetData()->Init() ) + wxModule *module = node->GetData(); + if ( !module->Init() ) { + wxLogError(_("Module \"%s\" initialization failed"), + module->GetClassInfo()->GetClassName()); + // clean up already initialized modules - process in reverse order wxModuleList::compatibility_iterator n; for ( n = node->GetPrevious(); n; n = n->GetPrevious() ) -- 2.45.2