From 1f02bd514782e6927fb078d5a4c66fec609a554a Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Mon, 2 Nov 2020 13:05:05 -0700 Subject: [PATCH] Use std::function instead of a function pointer in packet_analysis::Component --- src/packet_analysis/Component.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/packet_analysis/Component.h b/src/packet_analysis/Component.h index 61986719f7..1a93e4cc76 100644 --- a/src/packet_analysis/Component.h +++ b/src/packet_analysis/Component.h @@ -17,7 +17,7 @@ using AnalyzerPtr = std::shared_ptr; class Component : public plugin::Component, public plugin::TaggedComponent { public: - typedef AnalyzerPtr (*factory_callback)(); + using factory_callback = std::function; Component(const std::string& name, factory_callback factory, Tag::subtype_t subtype = 0); ~Component() override = default;