diff --git a/devicehandlers/DeviceHandlerBase.cpp b/devicehandlers/DeviceHandlerBase.cpp index 63c7951c..16be66fa 100644 --- a/devicehandlers/DeviceHandlerBase.cpp +++ b/devicehandlers/DeviceHandlerBase.cpp @@ -44,6 +44,7 @@ DeviceHandlerBase::DeviceHandlerBase(object_id_t setObjectId, } DeviceHandlerBase::~DeviceHandlerBase() { + //communicationInterface->close(cookie); delete comCookie; if (defaultFDIRUsed) { delete fdirInstance; @@ -355,9 +356,9 @@ ReturnValue_t DeviceHandlerBase::insertInReplyMap(DeviceCommandId_t replyId, info.command = deviceCommandMap.end(); auto resultPair = deviceReplyMap.emplace(replyId, info); if (resultPair.second) { - return HasReturnvaluesIF::RETURN_OK; + return RETURN_OK; } else { - return HasReturnvaluesIF::RETURN_FAILED; + return RETURN_FAILED; } } @@ -368,9 +369,9 @@ ReturnValue_t DeviceHandlerBase::insertInCommandMap(DeviceCommandId_t deviceComm info.sendReplyTo = NO_COMMANDER; auto resultPair = deviceCommandMap.emplace(deviceCommand, info); if (resultPair.second) { - return HasReturnvaluesIF::RETURN_OK; + return RETURN_OK; } else { - return HasReturnvaluesIF::RETURN_FAILED; + return RETURN_FAILED; } } diff --git a/devicehandlers/DeviceHandlerBase.h b/devicehandlers/DeviceHandlerBase.h index e7a8032d..454f0751 100644 --- a/devicehandlers/DeviceHandlerBase.h +++ b/devicehandlers/DeviceHandlerBase.h @@ -481,9 +481,11 @@ public: */ virtual void setParentQueue(MessageQueueId_t parentQueueId); + /** @brief Implementation required for HasActionIF */ ReturnValue_t executeAction(ActionId_t actionId, MessageQueueId_t commandedBy, const uint8_t* data, size_t size) override; + Mode_t getTransitionSourceMode() const; Submode_t getTransitionSourceSubMode() const; virtual void getMode(Mode_t *mode, Submode_t *submode); @@ -669,7 +671,7 @@ protected: * Optional Error code * Can be set in doStartUp(), doShutDown() and doTransition() to signal cause for Transition failure. */ - ReturnValue_t childTransitionFailure = HasReturnvaluesIF::RETURN_OK; + ReturnValue_t childTransitionFailure; uint32_t ignoreMissedRepliesCount = 0; //!< Counts if communication channel lost a reply, so some missed replys can be ignored.