diff --git a/src/app/clusters/basic/basic.cpp b/src/app/clusters/basic/basic.cpp index 9780bc6d4852af..6454f6a5d05d86 100644 --- a/src/app/clusters/basic/basic.cpp +++ b/src/app/clusters/basic/basic.cpp @@ -344,9 +344,10 @@ class PlatformMgrDelegate : public DeviceLayer::PlatformManagerDelegate Events::StartUp::Type event{ softwareVersion }; EventNumber eventNumber; - if (CHIP_NO_ERROR != LogEvent(event, endpoint, eventNumber, EventOptions::Type::kUrgent)) + CHIP_ERROR err = LogEvent(event, endpoint, eventNumber, EventOptions::Type::kUrgent); + if (CHIP_NO_ERROR != err) { - ChipLogError(Zcl, "PlatformMgrDelegate: Failed to record StartUp event"); + ChipLogError(Zcl, "PlatformMgrDelegate: Failed to record StartUp event: %" CHIP_ERROR_FORMAT, err.Format()); } } } @@ -362,9 +363,10 @@ class PlatformMgrDelegate : public DeviceLayer::PlatformManagerDelegate Events::ShutDown::Type event; EventNumber eventNumber; - if (CHIP_NO_ERROR != LogEvent(event, endpoint, eventNumber, EventOptions::Type::kUrgent)) + CHIP_ERROR err = LogEvent(event, endpoint, eventNumber, EventOptions::Type::kUrgent); + if (CHIP_NO_ERROR != err) { - ChipLogError(Zcl, "PlatformMgrDelegate: Failed to record ShutDown event"); + ChipLogError(Zcl, "PlatformMgrDelegate: Failed to record ShutDown event: %" CHIP_ERROR_FORMAT, err.Format()); } } }