From 76fb2ea93b1bb8bc55a06449e180a5c6dc15eca6 Mon Sep 17 00:00:00 2001 From: Vladimir 'phcoder' Serbinenko Date: Fri, 10 Feb 2012 12:54:40 +0100 Subject: [PATCH] * util/grub-script-check.c (argp_parser): Remove unused variable. (main): Rename read to curread to avoid shadowing. --- ChangeLog | 5 +++++ util/grub-script-check.c | 8 +++----- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 4606a769e..2d5a3cd5e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2012-02-10 Vladimir Serbinenko + + * util/grub-script-check.c (argp_parser): Remove unused variable. + (main): Rename read to curread to avoid shadowing. + 2012-02-10 Vladimir Serbinenko * util/misc.c (grub_util_write_image_at): Fix format specification. diff --git a/util/grub-script-check.c b/util/grub-script-check.c index 5a0e2fc28..97b9969ef 100644 --- a/util/grub-script-check.c +++ b/util/grub-script-check.c @@ -56,8 +56,6 @@ argp_parser (int key, char *arg, struct argp_state *state) know is a pointer to our arguments structure. */ struct arguments *arguments = state->input; - char *p; - switch (key) { case 'v': @@ -102,10 +100,10 @@ main (int argc, char *argv[]) int i; char *cmdline = 0; size_t len = 0; - ssize_t read; + ssize_t curread; - read = getline(&cmdline, &len, (file ?: stdin)); - if (read == -1) + curread = getline(&cmdline, &len, (file ?: stdin)); + if (curread == -1) { *line = 0; grub_errno = GRUB_ERR_READ_ERROR;