grub2/0265-Fix-const-char-pointers-in-grub-core-net-url.c.patch
Peter Jones 47cf63735c "Minor" bug fixes
Resolves: CVE-2020-10713
Resolves: CVE-2020-14308
Resolves: CVE-2020-14309
Resolves: CVE-2020-14310
Resolves: CVE-2020-14311
Resolves: CVE-2020-15705
Resolves: CVE-2020-15706
Resolves: CVE-2020-15707

Signed-off-by: Peter Jones <pjones@redhat.com>
2020-08-10 22:02:39 -04:00

28 lines
1 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 20 Jul 2020 12:24:02 -0400
Subject: [PATCH] Fix const char ** pointers in grub-core/net/url.c
This will need to get folded back in the right place on the next rebase,
but it's before "Make grub_strtol() "end" pointers have safer const
qualifiers" currently, so for now I'm leaving it here instead of merging
it back with the original patch.
Signed-off-by: Peter Jones <pjones@redhat.com>
---
grub-core/net/url.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/grub-core/net/url.c b/grub-core/net/url.c
index 146858284cd..d9d2fc9a9dc 100644
--- a/grub-core/net/url.c
+++ b/grub-core/net/url.c
@@ -235,7 +235,7 @@ extract_http_url_info (char *url, int ssl,
c = *port_end;
*port_end = '\0';
- portul = grub_strtoul (port_off, &separator, 10);
+ portul = grub_strtoul (port_off, (const char **)&separator, 10);
*port_end = c;
#ifdef URL_TEST
if (portul == ULONG_MAX && errno == ERANGE)