[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v5 08/13] error: Use PRI* macros to get correct format string cod
From: |
Glenn Washburn |
Subject: |
[PATCH v5 08/13] error: Use PRI* macros to get correct format string code across architectures |
Date: |
Wed, 3 Mar 2021 19:29:13 -0600 |
Also remove casting of format string args so that the architecture dependent
type is preserved.
Signed-off-by: Glenn Washburn <development@efficientek.com>
---
grub-core/loader/i386/pc/linux.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/grub-core/loader/i386/pc/linux.c b/grub-core/loader/i386/pc/linux.c
index 814988ab9..2a2995201 100644
--- a/grub-core/loader/i386/pc/linux.c
+++ b/grub-core/loader/i386/pc/linux.c
@@ -230,9 +230,10 @@ grub_cmd_linux (grub_command_t cmd __attribute__
((unused)),
&& GRUB_LINUX_ZIMAGE_ADDR + grub_linux16_prot_size
> grub_linux_real_target)
{
- grub_error (GRUB_ERR_BAD_OS, "too big zImage (0x%x > 0x%x), use bzImage
instead",
- (char *) GRUB_LINUX_ZIMAGE_ADDR + grub_linux16_prot_size,
- (grub_size_t) grub_linux_real_target);
+ grub_error (GRUB_ERR_BAD_OS, "too big zImage (0x%" PRIxGRUB_SIZE
+ " > 0x%" PRIxGRUB_ADDR "), use bzImage instead",
+ GRUB_LINUX_ZIMAGE_ADDR + grub_linux16_prot_size,
+ grub_linux_real_target);
goto fail;
}
--
2.27.0
- [PATCH v5 00/13] error: Do compile-time format string checking on grub_error, Glenn Washburn, 2021/03/03
- [PATCH v5 01/13] misc: Format string for grub_error should be a literal, Glenn Washburn, 2021/03/03
- [PATCH v5 02/13] error: grub_error missing format string argument, Glenn Washburn, 2021/03/03
- [PATCH v5 03/13] error: grub_error format string add missing format code, Glenn Washburn, 2021/03/03
- [PATCH v5 04/13] dmraid_nvidia: Format string error in grub_error, Glenn Washburn, 2021/03/03
- [PATCH v5 05/13] grub_error: Use format code PRIuGRUB_SIZE for variables of type grub_size_t, Glenn Washburn, 2021/03/03
- [PATCH v5 06/13] pgp: Format code for grub_error is incorrect, Glenn Washburn, 2021/03/03
- [PATCH v5 07/13] efi: Format string error in grub_error, Glenn Washburn, 2021/03/03
- [PATCH v5 08/13] error: Use PRI* macros to get correct format string code across architectures,
Glenn Washburn <=
- [PATCH v5 09/13] error: Use format code PRIxGRUB_UINT64_T for 64-bit uint argument in grub_error, Glenn Washburn, 2021/03/03
- [PATCH v5 10/13] error: Use format code PRIxGRUB_UINT64_T for 64-bit arg in grub_error, Glenn Washburn, 2021/03/03
- [PATCH v5 11/13] error: Use format code PRIuGRUB_UINT64_T for 64-bit typed fileblock in grub_error, Glenn Washburn, 2021/03/03
- [PATCH v5 12/13] error: Use format code llu for 64-bit uint bp->blk_prop in grub_error, Glenn Washburn, 2021/03/03
- [PATCH v5 13/13] error: Do compile-time format string checking on grub_error, Glenn Washburn, 2021/03/03