Skip to content

Commit ddf9a7a

Browse files
ThePassionatepkarashchenko
authored andcommitted
system/adb: fix build warning
adb_banner.c:60:47: error: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'uint32_t' {aka 'long unsigned int'} [-Werror=format=] Signed-off-by: makejian <[email protected]>
1 parent c9223af commit ddf9a7a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

system/adb/adb_banner.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,8 @@ int adb_fill_connect_data(char *buf, size_t bufsize)
5757
{
5858
/* FIXME only keep first 4 bytes */
5959

60-
len = snprintf(buf, remaining, "device:%x:", *(uint32_t *)board_id);
60+
len = snprintf(buf, remaining,
61+
"device:%" PRIx32 ":", *(uint32_t *)board_id);
6162
}
6263
#else
6364
len = snprintf(buf, remaining, "device:" CONFIG_ADBD_DEVICE_ID ":");

0 commit comments

Comments
 (0)