Use correct inttypes.h format specifier
The type here is uint32_t which should use PRIx32, not plain %x which is for an int, we've just gotten away with it so far. Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
7150286225
commit
6ce585ac15
1 changed files with 2 additions and 1 deletions
3
util.c
3
util.c
|
@ -13,6 +13,7 @@
|
|||
#include <stdarg.h>
|
||||
#include <string.h>
|
||||
#include <assert.h>
|
||||
#include <inttypes.h>
|
||||
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
|
@ -393,7 +394,7 @@ void utilfdt_print_data(const char *data, int len)
|
|||
|
||||
printf(" = <");
|
||||
for (i = 0, len /= 4; i < len; i++)
|
||||
printf("0x%08x%s", fdt32_to_cpu(cell[i]),
|
||||
printf("0x%08" PRIx32 "%s", fdt32_to_cpu(cell[i]),
|
||||
i < (len - 1) ? " " : "");
|
||||
printf(">");
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue