nalika / rpms / grub2

Forked from rpms/grub2 2 years ago
Clone

Blame SOURCES/0095-Fix-crash-on-http.patch

23d2ea
From b01ecf0925ea952e2febb4a50f84f45c7b60ada3 Mon Sep 17 00:00:00 2001
606ea6
From: Gustavo Luiz Duarte <gustavold@linux.vnet.ibm.com>
606ea6
Date: Tue, 25 Sep 2012 18:40:55 -0400
23d2ea
Subject: [PATCH 095/198] Fix crash on http
606ea6
606ea6
Don't free file->data on receiving FIN flag since it is used all over without
606ea6
checking. http_close() will be called later to free that memory.
606ea6
https://bugzilla.redhat.com/show_bug.cgi?id=860834
606ea6
---
606ea6
 grub-core/net/http.c | 2 +-
606ea6
 1 file changed, 1 insertion(+), 1 deletion(-)
606ea6
606ea6
diff --git a/grub-core/net/http.c b/grub-core/net/http.c
606ea6
index 4684f8b..ef9538c 100644
606ea6
--- a/grub-core/net/http.c
606ea6
+++ b/grub-core/net/http.c
606ea6
@@ -393,7 +393,7 @@ http_establish (struct grub_file *file, grub_off_t offset, int initial)
606ea6
 
606ea6
   data->sock = grub_net_tcp_open (file->device->net->server,
606ea6
 				  HTTP_PORT, http_receive,
606ea6
-				  http_err, http_err,
606ea6
+				  http_err, NULL,
606ea6
 				  file);
606ea6
   if (!data->sock)
606ea6
     {
606ea6
-- 
23d2ea
2.7.4
606ea6