Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/lib/libcurses/slave tests/libcurses: KNF for while loop



details:   https://anonhg.NetBSD.org/src/rev/af3fe4048ae4
branches:  trunk
changeset: 379671:af3fe4048ae4
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sun Jun 13 19:13:20 2021 +0000

description:
tests/libcurses: KNF for while loop

diffstat:

 tests/lib/libcurses/slave/curses_commands.c |  6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diffs (20 lines):

diff -r 3383fae4ed15 -r af3fe4048ae4 tests/lib/libcurses/slave/curses_commands.c
--- a/tests/lib/libcurses/slave/curses_commands.c       Sun Jun 13 18:11:44 2021 +0000
+++ b/tests/lib/libcurses/slave/curses_commands.c       Sun Jun 13 19:13:20 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: curses_commands.c,v 1.26 2021/06/13 18:11:44 rillig Exp $      */
+/*     $NetBSD: curses_commands.c,v 1.27 2021/06/13 19:13:20 rillig Exp $      */
 
 /*-
  * Copyright 2009 Brett Lymn <blymn%NetBSD.org@localhost>
@@ -165,7 +165,9 @@ cmd_DRAIN(int nargs, char **args)
        ARGC(1);
        ARG_WINDOW(win);
 
-       while (wgetch(win) != ERR);
+       while (wgetch(win) != ERR)
+               continue;
+
        report_count(1);
        report_return(OK);
 }



Home | Main Index | Thread Index | Old Index