From c0c37d87f5aba0a088da6173102ffec9f52c7318 Mon Sep 17 00:00:00 2001 From: Andrea Terzolo Date: Tue, 20 Sep 2022 15:07:59 +0000 Subject: [PATCH] fix(process_events): check the return value of `open_live_inspector` Signed-off-by: Andrea Terzolo --- userspace/falco/app_actions/process_events.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/userspace/falco/app_actions/process_events.cpp b/userspace/falco/app_actions/process_events.cpp index f5872bc5..22c20687 100644 --- a/userspace/falco/app_actions/process_events.cpp +++ b/userspace/falco/app_actions/process_events.cpp @@ -335,7 +335,12 @@ application::run_result application::process_events() try { falco_logger::log(LOG_DEBUG, "Opening event source '" + source + "'\n"); - open_live_inspector(src_info->inspector, source); + res = open_live_inspector(src_info->inspector, source); + if (!res.success) + { + return res; + } + if (m_state->enabled_sources.size() == 1) { // optimization: with only one source we don't spawn additional threads