Blame SOURCES/0258-HTTP-boot-strncmp-returns-0-on-equal.patch

e0db32
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
e0db32
From: Stephen Benjamin <stephen@redhat.com>
e0db32
Date: Fri, 12 Apr 2019 10:43:13 -0400
e0db32
Subject: [PATCH] HTTP boot: strncmp returns 0 on equal
e0db32
e0db32
Resolves: rhbz#1490991
e0db32
---
e0db32
 grub-core/net/efi/http.c | 2 +-
e0db32
 1 file changed, 1 insertion(+), 1 deletion(-)
e0db32
e0db32
diff --git a/grub-core/net/efi/http.c b/grub-core/net/efi/http.c
e0db32
index 2a9624dacc4..484e0c68cee 100644
e0db32
--- a/grub-core/net/efi/http.c
e0db32
+++ b/grub-core/net/efi/http.c
e0db32
@@ -19,7 +19,7 @@ http_configure (struct grub_efi_net_device *dev, int prefer_ip6)
e0db32
   const char *rest, *http_server, *http_path = NULL;
e0db32
 
e0db32
   http_server = grub_env_get ("root");
e0db32
-  https = grub_strncmp (http_server, "https", 5) ? 1 : 0;
e0db32
+  https = (grub_strncmp (http_server, "https", 5) == 0) ? 1 : 0;
e0db32
 
e0db32
   /* extract http server + port */
e0db32
   if (http_server)