diff --git a/src/controller/CHIPDeviceController.cpp b/src/controller/CHIPDeviceController.cpp index 51e59c92eb053a..2456fb66443b35 100644 --- a/src/controller/CHIPDeviceController.cpp +++ b/src/controller/CHIPDeviceController.cpp @@ -301,8 +301,8 @@ CHIP_ERROR DeviceController::Shutdown() // ReturnErrorOnFailure(DeviceLayer::PlatformMgr().Shutdown()); #else - mInetLayer->Shutdown(); - mSystemLayer->Shutdown(); + VerifyOrReturnError(mInetLayer->Shutdown() == INET_NO_ERROR, CHIP_ERROR_INTERNAL); + VerifyOrReturnError(mSystemLayer->Shutdown() == CHIP_SYSTEM_NO_ERROR, CHIP_ERROR_INTERNAL); chip::Platform::Delete(mInetLayer); chip::Platform::Delete(mSystemLayer); #endif // CONFIG_DEVICE_LAYER