diff --git a/openthread b/openthread index 2868c9c..f0d6007 160000 --- a/openthread +++ b/openthread @@ -1 +1 @@ -Subproject commit 2868c9ce6b6716d97b6f0811ea3bc8f7647ace0f +Subproject commit f0d6007cc3a2b85c9c311756da2da9e01ad25a98 diff --git a/src/imx_rt/platform/spinel_hdlc.cpp b/src/imx_rt/platform/spinel_hdlc.cpp index 2d13194..62a83d8 100644 --- a/src/imx_rt/platform/spinel_hdlc.cpp +++ b/src/imx_rt/platform/spinel_hdlc.cpp @@ -31,7 +31,7 @@ #include "fsl_component_serial_manager.h" #include "fsl_os_abstraction.h" -#include "lib/utils/utils.hpp" +#include "common/code_utils.hpp" #include #include @@ -130,11 +130,11 @@ otError HdlcInterface::SendFrame(const uint8_t *aFrame, uint16_t aLength) otError error = OT_ERROR_NONE; assert(encoderBuffer.IsEmpty()); - EXPECT_NO_ERROR(error = mHdlcEncoder.BeginFrame()); - EXPECT_NO_ERROR(error = mHdlcEncoder.Encode(aFrame, aLength)); - EXPECT_NO_ERROR(error = mHdlcEncoder.EndFrame()); + SuccessOrExit(error = mHdlcEncoder.BeginFrame()); + SuccessOrExit(error = mHdlcEncoder.Encode(aFrame, aLength)); + SuccessOrExit(error = mHdlcEncoder.EndFrame()); OT_PLAT_DBG("frame len to send = %d/%d", encoderBuffer.GetLength(), aLength); - EXPECT_NO_ERROR(error = Write(encoderBuffer.GetFrame(), encoderBuffer.GetLength())); + SuccessOrExit(error = Write(encoderBuffer.GetFrame(), encoderBuffer.GetLength())); exit: if (error != OT_ERROR_NONE)