From: Paul Fertser Date: Fri, 17 Jan 2014 11:17:14 +0000 (+0400) Subject: flash/nor/stm32f1x: fix format specifiers warning X-Git-Tag: v0.8.0-rc1~95 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=da9bee3ede482556865568b148aecb0ff5f06a62;p=openocd flash/nor/stm32f1x: fix format specifiers warning Caught by clang on OS X. Reported by Steffanx on IRC. Change-Id: Id77c7297c58e58c4e2aa8e5dafcb3a29a1f33f3d Signed-off-by: Paul Fertser Reviewed-on: http://openocd.zylin.com/1879 Tested-by: jenkins Reviewed-by: Xiaofan Reviewed-by: Spencer Oliver --- diff --git a/src/flash/nor/stm32f1x.c b/src/flash/nor/stm32f1x.c index ce0708f6..30652c6f 100644 --- a/src/flash/nor/stm32f1x.c +++ b/src/flash/nor/stm32f1x.c @@ -1347,9 +1347,9 @@ COMMAND_HANDLER(stm32x_handle_options_read_command) } command_print(CMD_CTX, "User Option0: 0x%02" PRIx8, - (user_data >> stm32x_info->user_data_offset) & 0xff); + (uint8_t)((user_data >> stm32x_info->user_data_offset) & 0xff)); command_print(CMD_CTX, "User Option1: 0x%02" PRIx8, - (user_data >> (stm32x_info->user_data_offset + 8)) & 0xff); + (uint8_t)((user_data >> (stm32x_info->user_data_offset + 8)) & 0xff)); return ERROR_OK; }