From: Benno Schulenberg Date: Fri, 10 Jul 2015 16:00:12 +0000 (+0000) Subject: Eliding an unneeded variable. X-Git-Tag: v2.5.0~173 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=ea4b775a3e8ffc633d68ea2d3316e83f79785c92;p=nano.git Eliding an unneeded variable. git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5289 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- diff --git a/ChangeLog b/ChangeLog index e6da1eff..e052bd28 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,7 @@ * src/nano.c (delete_opennode): Plug a small memory leak. * src/files.c (do_lockfile): Rename a variable; it does not contain the size of the file but the size of the name. + * src/nano.c (do_toggle): Elide an unneeded variable. 2015-07-06 Benno Schulenberg * src/global.c (add_to_sclist), src/help.c (help_init), src/nano.h, diff --git a/src/nano.c b/src/nano.c index 7fc8a429..b7d76402 100644 --- a/src/nano.c +++ b/src/nano.c @@ -1413,7 +1413,6 @@ void allow_pending_sigwinch(bool allow) void do_toggle(int flag) { bool enabled; - const char *desc; TOGGLE(flag); @@ -1457,8 +1456,7 @@ void do_toggle(int flag) ) enabled = !enabled; - desc = (char *) _(flagtostr(flag)); - statusbar("%s %s", desc, enabled ? _("enabled") : _("disabled")); + statusbar("%s %s", _(flagtostr(flag)), enabled ? _("enabled") : _("disabled")); } #endif /* !NANO_TINY */