97
97
std::string plugin_name(boost::to_lower_copy(plugin->getName()));
98
98
if (find_ptr(plugin_registry, std::make_pair(plugin_type, plugin_name)))
100
errmsg_printf(error::ERROR, _("Loading plugin %s failed: a %s plugin by that name already exists.\n"),
101
plugin->getTypeName().c_str(), plugin->getName().c_str());
104
if (T::addPlugin(plugin)) // Olaf: Should addPlugin be called when failed is already true?
100
std::string error_message;
101
error_message+= _("Loading plugin failed, a plugin by that name already exists.");
102
error_message+= plugin->getTypeName();
104
error_message+= plugin->getName();
105
unireg_actual_abort(__FILE__, __LINE__, __func__, error_message);
108
if (T::addPlugin(plugin))
110
std::string error_message;
111
error_message+= _("Fatal error: Failed initializing: ");
112
error_message+= plugin->getTypeName();
114
error_message+= plugin->getName();
115
unireg_actual_abort(__FILE__, __LINE__, __func__, error_message);
109
errmsg_printf(error::ERROR, _("Fatal error: Failed initializing %s::%s plugin.\n"),
110
plugin->getTypeName().c_str(), plugin->getName().c_str());
120
unireg_abort << _("Fatal error: Failed initializing: ") << plugin->getTypeName() << ":" << plugin->getName();
113
122
plugin_registry.insert(std::make_pair(std::make_pair(plugin_type, plugin_name), plugin));