From 7b839430597ddef35221ad1ecd2801c862f4de1c Mon Sep 17 00:00:00 2001 From: Aldo Lacuku Date: Thu, 9 Jun 2022 11:43:29 +0200 Subject: [PATCH] fix(falco): compilation issues with new libs version Signed-off-by: Aldo Lacuku --- userspace/falco/app_actions/load_plugins.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/userspace/falco/app_actions/load_plugins.cpp b/userspace/falco/app_actions/load_plugins.cpp index 283498ba..9604d866 100644 --- a/userspace/falco/app_actions/load_plugins.cpp +++ b/userspace/falco/app_actions/load_plugins.cpp @@ -31,11 +31,16 @@ application::run_result application::load_plugins() // The only enabled event source is syscall by default m_state->enabled_sources = {falco_common::syscall_source}; + std::string err = ""; std::shared_ptr loaded_plugin = nullptr; for(auto &p : m_state->config->m_plugins) { falco_logger::log(LOG_INFO, "Loading plugin (" + p.m_name + ") from file " + p.m_library_path + "\n"); - auto plugin = m_state->inspector->register_plugin(p.m_library_path, p.m_init_config); + auto plugin = m_state->inspector->register_plugin(p.m_library_path); + if (!plugin->init(p.m_init_config, err)) + { + return run_result::fatal(err); + } if(plugin->caps() & CAP_SOURCING) {