mirror of
https://github.com/zeek/zeek.git
synced 2025-10-06 00:28:21 +00:00
Merge remote-tracking branch 'origin/topic/awelzel/duplicate-plugin-no-debug'
* origin/topic/awelzel/duplicate-plugin-no-debug: plugin/Manager: Warn when plugin with the same name is found
This commit is contained in:
commit
5a9c6d4633
5 changed files with 49 additions and 4 deletions
|
@ -112,10 +112,10 @@ void Manager::SearchDynamicPlugins(const std::string& dir)
|
|||
if ( name.empty() )
|
||||
reporter->FatalError("empty plugin magic file %s", magic.c_str());
|
||||
|
||||
if ( dynamic_plugins.find(lower_name) != dynamic_plugins.end() )
|
||||
if ( const auto& other = dynamic_plugins.find(lower_name); other != dynamic_plugins.end() )
|
||||
{
|
||||
DBG_LOG(DBG_PLUGINS, "Found already known plugin %s in %s, ignoring", name.c_str(),
|
||||
dir.c_str());
|
||||
reporter->Warning("ignoring dynamic plugin %s from %s, already found in %s",
|
||||
name.c_str(), dir.c_str(), other->second.c_str());
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue