[build] add format-nonliteral to missed code (#12251)

This commit enables the format-nonliteral check for code missed in
`#12236`. This commit also enables the format-nonliteral warnings in
CMake to catch such warnings in future in CMake build.
This commit is contained in:
Yakun Xu
2026-01-06 14:53:38 -08:00
committed by GitHub
parent bcc41e9b44
commit 31631142c2
25 changed files with 104 additions and 58 deletions
+1 -1
View File
@@ -383,6 +383,7 @@ void otMacFrameUpdateTimeIe(otRadioFrame *aFrame, uint64_t aRadioTime, otRadioCo
uint8_t *timeIe;
uint64_t time;
OT_UNUSED_VARIABLE(aRadioContext);
VerifyOrExit((aFrame->mInfo.mTxInfo.mIeInfo != nullptr) && (aFrame->mInfo.mTxInfo.mIeInfo->mTimeIeOffset != 0));
timeIe = aFrame->mPsdu + aFrame->mInfo.mTxInfo.mIeInfo->mTimeIeOffset;
@@ -434,7 +435,6 @@ bool otMacFrameSrcAddrMatchCslReceiverPeer(const otRadioFrame *aFrame, const otR
break;
case Mac::Address::kTypeExtended:
VerifyOrExit(*reinterpret_cast<const uint64_t *>(aRadioContext->mCslExtAddress.m8) != 0);
VerifyOrExit(src.GetExtended() == *static_cast<const Mac::ExtAddress *>(&aRadioContext->mCslExtAddress));
matches = true;
break;