From ff783628268470acc02e52126d6a357691723fba Mon Sep 17 00:00:00 2001 From: C. McEnroe Date: Mon, 30 Mar 2020 19:44:45 -0400 Subject: Replace some declaration; while loops with for loops I should have been using this for getopt loops already but the call here is slightly too long to fit on one line as a for loop. --- ui.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'ui.c') diff --git a/ui.c b/ui.c index 9c1b238..02f8979 100644 --- a/ui.c +++ b/ui.c @@ -945,10 +945,9 @@ void uiRead(void) { } } - int ret; wint_t ch; static bool paste, style; - while (ERR != (ret = wget_wch(input, &ch))) { + for (int ret; ERR != (ret = wget_wch(input, &ch));) { if (ret == KEY_CODE_YES && ch == KeyPasteOn) { paste = true; } else if (ret == KEY_CODE_YES && ch == KeyPasteOff) { -- cgit 1.4.1-2-gfad0