From e6e1cad743d04f79148c92bab774fed183ff43a6 Mon Sep 17 00:00:00 2001 From: steviez Date: Tue, 11 Feb 2020 13:11:33 -0600 Subject: rfnoc: actions: Cleanup rx_event_action_info ctor Set error code member variable in rx_event_action_info constructor instead of relying on the caller to set it after object creation --- host/include/uhd/rfnoc/actions.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'host/include') diff --git a/host/include/uhd/rfnoc/actions.hpp b/host/include/uhd/rfnoc/actions.hpp index 681a9da3d..52e6b9287 100644 --- a/host/include/uhd/rfnoc/actions.hpp +++ b/host/include/uhd/rfnoc/actions.hpp @@ -70,13 +70,13 @@ public: using sptr = std::shared_ptr; //! The error code that describes the event - uhd::rx_metadata_t::error_code_t error_code = uhd::rx_metadata_t::ERROR_CODE_NONE; + uhd::rx_metadata_t::error_code_t error_code; //! Factory function - static sptr make(); + static sptr make(uhd::rx_metadata_t::error_code_t error_code); -private: - rx_event_action_info(); +protected: + rx_event_action_info(uhd::rx_metadata_t::error_code_t error_code); }; struct UHD_API tx_event_action_info : public action_info -- cgit v1.2.3