Signed-off-by: Glenn Washburn
---
grub-core/fs/hfsplus.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/grub-core/fs/hfsplus.c b/grub-core/fs/hfsplus.c
index 361e5be49..2a69055c7 100644
--- a/grub-core/fs/hfsplus.c
+++ b/grub-core/fs/hfsplus.c
@@ -199,7 +199,8 @@ grub_hfspl
This should help prevent format string errors and thus improve the quality
of error reporting.
Signed-off-by: Glenn Washburn
---
include/grub/err.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/grub/err.h b/include/grub/err.h
index 24ba9f5f5..b08d5d0de 100644
---
The underlying type of grub_uint64_t changes across architectures, but 1ULL
does not. This allows using these macros as arguments to format string
functions that use the PRI* format string macros that also vary with
architecture.
Change the grub_error call, where this was previously an issue and
t
The macro ELF_R_TYPE does not change the underlying type. Here its argument
is a 64-bit Elf64_Xword. Make sure the format code matches.
For the riscv architecture, rel->r_info could be either Elf32_Xword or
Elf64_Xword depending on if 32 or 64-bit risc is being built. So cast to
64-bit value regar
Also remove casting of format string args so that the architecture dependent
type is preserved.
Signed-off-by: Glenn Washburn
---
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/p
Signed-off-by: Glenn Washburn
---
grub-core/disk/cryptodisk.c| 12
grub-core/kern/efi/efi.c | 2 +-
grub-core/loader/efi/chainloader.c | 2 +-
grub-core/loader/i386/bsd.c| 3 ++-
4 files changed, 12 insertions(+), 7 deletions(-)
diff --git a/grub-core/di
This is a temporary, less-intrusive change to get the build to success with
compiler format string checking turned on. There is a better fix which
addresses this issue, but it needs more testing. Use this change so that
format string checking on grub_error can be turned on until the better
change i
The format code is for a 32-bit int, but the argument, keyid, is declared as
a 64 bit int. The comment above says keyid is 32-bit. I'm not sure if the
comment or declaration is wrong, so force the display of a 64-bit int for
now.
Signed-off-by: Glenn Washburn
---
grub-core/commands/pgp.c | 4 ++-
Signed-off-by: Glenn Washburn
---
grub-core/loader/efi/chainloader.c | 2 +-
grub-core/net/tftp.c | 2 +-
grub-core/script/lexer.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/grub-core/loader/efi/chainloader.c
b/grub-core/loader/efi/chainloader.
Signed-off-by: Glenn Washburn
---
grub-core/disk/ata.c | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/grub-core/disk/ata.c b/grub-core/disk/ata.c
index 685f33a19..3620a282e 100644
--- a/grub-core/disk/ata.c
+++ b/grub-core/disk/ata.c
@@ -219,8 +219,9 @@ grub_ata_se
The grub_error has a format string expecting two arguments, but only one
provided. According to the comments in the struct grub_nv_super definition,
the version field looks like a version number where major.minor is encoded
as each a byte in the two-byte short.
Signed-off-by: Glenn Washburn
---
Signed-off-by: Glenn Washburn
---
grub-core/video/bochs.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/grub-core/video/bochs.c b/grub-core/video/bochs.c
index 7a249eb21..30ea1bd82 100644
--- a/grub-core/video/bochs.c
+++ b/grub-core/video/bochs.c
@@ -249,11 +249,11 @@ g
The second format string argument, GRUB_EFI_MAX_USABLE_ADDRESS, is a macro
to a number literal. However depending on what the target architecture, the
type can be 32 or 64 bits. Cast to a 64-bit integer. Also, change the
format string literals %llx to use PRIxGRUB_UINT64_T.
Signed-off-by: Glenn W
Its obvious from the error message that the variable named "type" was
accidentally omitted.
Signed-off-by: Glenn Washburn
---
grub-core/parttool/msdospart.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/grub-core/parttool/msdospart.c b/grub-core/parttool/msdospart.c
ind
Daniel, you mentioned wanting a separate patch series which is the real fix
for patch #12. I've added it to this patch series, since they go together.
I can send the single patch as a separate thread if that still desirable.
Changes since v5
* Fix formatting issues with spaces around format strin
On Thu, 4 Mar 2021 20:03:34 +0100
Daniel Kiper wrote:
> Does this patch fix all such issues in the GRUB source code?
>
> Daniel
I don't know and its unclear the scope of your question. However, this
is the grep I used to find these instances:
grep -rnE '\"PRI|PRI[a-zA-Z_0-9]+\"'
Glenn
> O
On Thu, 4 Mar 2021 18:59:53 +0100
Daniel Kiper wrote:
> On Wed, Mar 03, 2021 at 07:29:17PM -0600, Glenn Washburn wrote:
> > For some reason PRIuGRUB_UINT64_T is not expanding to llu, but to
> > lu, which causes the format string check to fail. Use literal and
> > force cast until this is debugged
Does this patch fix all such issues in the GRUB source code?
Daniel
On Wed, Mar 03, 2021 at 07:51:04PM -0600, Glenn Washburn wrote:
> Signed-off-by: Glenn Washburn
> ---
> grub-core/disk/luks2.c | 38 +++---
> grub-core/fs/xfs.c | 4 ++--
> 2 files changed,
Improve 'search' grub-shell command with functionality to search for
a partition by PARTUUID string. This is useful on systems where FSUUID
is not guaranteed to be constant, e.g. it is not preserved between
system updates, and modifying grub.cfg is undesired.
V2:
This patch is based on Michael Grz
On Wed, Mar 03, 2021 at 07:29:17PM -0600, Glenn Washburn wrote:
> For some reason PRIuGRUB_UINT64_T is not expanding to llu, but to lu, which
> causes the format string check to fail. Use literal and force cast until
> this is debugged.
We know the problem and how to fix it at this point. Though w
From: Egor Ignatov
Make backspace work in superuser login prompt.
The problem was that bidi logical to visual ignored BN type,
so you couldn't print control characters.
Use grub_printf() 3 times, because if you print "\b \b" at
once the cursor will get stuck on the second last character.
Resol
21 matches
Mail list logo