low-can-cb: Little opti
[apps/agl-service-can-low-level.git] / low-can-binding / binding / application.cpp
index 063a11d..0b8963c 100644 (file)
 #define MICROSECONDS_IN_SECOND 1000000
 #define ENGINE_VALUE_TIMEOUT   5
 
+application_t::application_t()
+       : can_bus_manager_{}
+       , message_set_{}
+{}
+
 /// @brief Return singleton instance of configuration object.
 application_t& application_t::instance()
 {
@@ -166,13 +171,9 @@ bool application_t::is_engine_on()
 
                if(sf.diagnostic_messages.front()->get_last_value_with_timestamp().first > 0 &&
                   std::difftime(std::time(nullptr), last_timestamp_in_s) < ENGINE_VALUE_TIMEOUT)
-               {
                        engine_on = true;
-               }
                else
-               {
                        AFB_NOTICE("is_engine_on: engine.speed diagnostic message found, but engine seems off");
-               }
        }
        else
        {