fix(c++): re-throw original exception rather than copy

Reported by cppcheck

Signed-off-by: Samuel Gaist <samuel.gaist@idiap.ch>
This commit is contained in:
Samuel Gaist 2024-02-13 23:32:06 +01:00 committed by poiana
parent 7a18795ca5
commit f3491d62c9

View File

@ -111,13 +111,13 @@ namespace falco
m_handled.store(true, std::memory_order_seq_cst); m_handled.store(true, std::memory_order_seq_cst);
} }
} }
catch (std::exception& e) catch (std::exception&)
{ {
if (triggered()) if (triggered())
{ {
m_handled.store(true, std::memory_order_seq_cst); m_handled.store(true, std::memory_order_seq_cst);
} }
throw e; throw;
} }
return true; return true;
} }