mirror of
https://github.com/zeek/zeek.git
synced 2025-10-04 15:48:19 +00:00
Don't call tokenize_string if the input string is empty
This commit is contained in:
parent
2e457eb3ea
commit
359b5547cd
1 changed files with 7 additions and 3 deletions
|
@ -359,10 +359,14 @@ void Manager::ActivateDynamicPlugins(bool all)
|
|||
|
||||
// Activate plugins that our environment tells us to.
|
||||
vector<string> p;
|
||||
util::tokenize_string(util::zeek_plugin_activate(), ",", &p);
|
||||
std::string plugin_activate = util::zeek_plugin_activate();
|
||||
if ( ! plugin_activate.empty() )
|
||||
{
|
||||
util::tokenize_string(util::zeek_plugin_activate(), ",", &p);
|
||||
|
||||
for ( const auto& x : p )
|
||||
plugins_to_activate.emplace(x, true);
|
||||
for ( const auto& x : p )
|
||||
plugins_to_activate.emplace(x, true);
|
||||
}
|
||||
|
||||
if ( all )
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue