Skip to content

Commit 702c2c0

Browse files
Log signed vs unsigned for TLV payloads.
Right now we just log the number when the type is integer. But people keep being confused why things don't work when they messed up unsigned vs signed bits. We should just log that information.
1 parent d87e006 commit 702c2c0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/app/MessageDef/MessageDefHelper.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ CHIP_ERROR CheckIMPayload(TLV::TLVReader & aReader, int aDepth, const char * aLa
140140

141141
// TODO: Figure out how to not use PRId64 here, since it's not supported
142142
// on all libcs.
143-
PRETTY_PRINT_SAMELINE("%" PRId64 ", ", value_s64);
143+
PRETTY_PRINT_SAMELINE("%" PRId64 " (signed), ", value_s64);
144144
break;
145145
}
146146

@@ -151,7 +151,7 @@ CHIP_ERROR CheckIMPayload(TLV::TLVReader & aReader, int aDepth, const char * aLa
151151

152152
// TODO: Figure out how to not use PRIu64 here, since it's not supported
153153
// on all libcs.
154-
PRETTY_PRINT_SAMELINE("%" PRIu64 ", ", value_u64);
154+
PRETTY_PRINT_SAMELINE("%" PRIu64 " (unsigned), ", value_u64);
155155
break;
156156
}
157157

0 commit comments

Comments
 (0)