Fixes printf formatting issues caused by the toolchain

This commit is contained in:
Alexandre Paillier
2022-05-04 11:27:51 +02:00
parent 4442ba5716
commit b6e4f887cb
2 changed files with 11 additions and 9 deletions

View File

@@ -137,7 +137,9 @@ static bool path_depth_list_pop(void)
PRINTF("Hash = 0x");
for (int idx = 0; idx < KECCAK256_HASH_BYTESIZE; ++idx)
{
PRINTF("%.02x", shash[idx]);
// manual 0 padding, %.02x not supported by toolchain
if (shash[idx] < 0x10) PRINTF("0");
PRINTF("%x", shash[idx]);
}
PRINTF("\n\n");
}