drop grub-1.99-handle-fwrite-return.patch fixed upstream

revno: 4320
committer: Vladimir 'phcoder' Serbinenko <phcoder@gmail.com>
branch nick: grub
timestamp: Thu 2012-05-10 09:39:11 +0200
message:
  	* util/grub-menulst2cfg.c (main): Check return value of fwrite.
  	* util/grub-mklayout.c (write_file): Likewise. New argument fname.
  	All users updated.
This commit is contained in:
Mads Kiilerich 2012-06-01 18:38:29 +02:00
parent a6e7ffd3f0
commit c3c573eb67
2 changed files with 0 additions and 60 deletions

View File

@ -1,59 +0,0 @@
From de1c35857ee803653d3ffd94eb5d3f3b45ab000e Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 2 Mar 2011 11:29:28 -0500
Subject: [PATCH] Don't ignore fwrite's return since we build with -Wno-unused.
---
util/grub-mklayout.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/util/grub-mklayout.c b/util/grub-mklayout.c
index 04501cb..beea3eb 100644
--- a/util/grub-mklayout.c
+++ b/util/grub-mklayout.c
@@ -324,6 +324,7 @@ write_file (FILE *out, struct grub_keyboard_layout *layout)
{
grub_uint32_t version;
unsigned i;
+ int rc;
version = grub_cpu_to_le32 (GRUB_KEYBOARD_LAYOUTS_VERSION);
@@ -342,10 +343,10 @@ write_file (FILE *out, struct grub_keyboard_layout *layout)
layout->keyboard_map_shift_l3[i]
= grub_cpu_to_le32(layout->keyboard_map_shift_l3[i]);
- fwrite (GRUB_KEYBOARD_LAYOUTS_FILEMAGIC, 1,
+ rc = fwrite (GRUB_KEYBOARD_LAYOUTS_FILEMAGIC, 1,
GRUB_KEYBOARD_LAYOUTS_FILEMAGIC_SIZE, out);
- fwrite (&version, sizeof (version), 1, out);
- fwrite (layout, 1, sizeof (*layout), out);
+ rc = fwrite (&version, sizeof (version), 1, out);
+ rc = fwrite (layout, 1, sizeof (*layout), out);
}
static void
--
1.7.3.1
diff --git a/util/grub-menulst2cfg.c b/util/grub-menulst2cfg.c
index 513af47..308f8e9 100644
--- a/util/grub-menulst2cfg.c
+++ b/util/grub-menulst2cfg.c
@@ -34,6 +34,7 @@ main (int argc, char **argv)
size_t bufsize = 0;
char *suffix = xstrdup ("");
int suffixlen = 0;
+ int rc;
if (argc >= 2 && argv[1][0] == '-')
{
@@ -111,7 +112,7 @@ main (int argc, char **argv)
if (entryname)
fprintf (out, "}\n\n");
- fwrite (suffix, 1, suffixlen, out);
+ rc = fwrite (suffix, 1, suffixlen, out);
free (buf);
free (suffix);

View File

@ -50,7 +50,6 @@ Source0: ftp://alpha.gnu.org/gnu/grub/grub-%{tarversion}.tar.xz
Source3: README.Fedora
Source4: http://unifoundry.com/unifont-5.1.20080820.pcf.gz
Source5: theme.tar.bz2
Patch0: grub-1.99-handle-fwrite-return.patch
Patch1: grub-1.99-grub_test_assert_printf.patch
Patch2: grub-1.99-just-say-linux.patch
Patch3: grub2-handle-initramfs-on-xen.patch