Skip to content

Commit

Permalink
fix(c++): don't throw outside of the try catch block in nothrow function
Browse files Browse the repository at this point in the history
Reported by cppcheck

Signed-off-by: Samuel Gaist <samuel.gaist@idiap.ch>
  • Loading branch information
sgaist committed Feb 13, 2024
1 parent 9bb42e8 commit e30475e
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions userspace/falco/app/actions/process_events.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -370,16 +370,17 @@ static void process_inspector_events(
{
sdropmgr.print_stats();
}

if (sync)
{
sync->finish();
}

}
catch(const std::exception& e)
{
*res = run_result::fatal(e.what());
}

if (sync)
{
sync->finish();
}
}

static falco::app::run_result init_stats_writer(
Expand Down

0 comments on commit e30475e

Please sign in to comment.