From b60eaface3b105b077b70cc9cb02ae729663a715 Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Wed, 4 Apr 2018 10:01:22 -0700 Subject: Fix precedence error in vmstat. toys/other/vmstat.c:98:12: error: logical not is only applied to the left hand side of this bitwise operator [-Werror,-Wlogical-not-parentheses] if ((!toys.optflags&FLAG_n) && isatty(1)) terminal_size(0, &rows); ^ ~ --- toys/other/vmstat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toys/other/vmstat.c b/toys/other/vmstat.c index 8e131d9f..44f73d49 100644 --- a/toys/other/vmstat.c +++ b/toys/other/vmstat.c @@ -95,7 +95,7 @@ void vmstat_main(void) if (rows>3 && !(loop % (rows-3))) { char *header = headers; - if ((!toys.optflags&FLAG_n) && isatty(1)) terminal_size(0, &rows); + if (!(toys.optflags&FLAG_n) && isatty(1)) terminal_size(0, &rows); else rows = 0; printf("procs -----------memory---------- ---swap-- -----io---- -system-- ----cpu----\n"); -- cgit v1.2.3