From: Kent R. Spillner Date: Sun, 11 Mar 2012 15:14:27 +0000 (-0500) Subject: Don't check if output changed on first screen. X-Git-Tag: v3.3.3~32^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ddfc402886eb215d34ce031a60a861e50e80a19a;p=procps-ng Don't check if output changed on first screen. When invoked with the --chgexit/-g options wait until we have at least one screen of output before checking if the output changed. Otherwise, we're comparing the initial screen of output to all spaces, which usually isn't what we want. --- diff --git a/watch.c b/watch.c index e3066f6f..6ce174ba 100644 --- a/watch.c +++ b/watch.c @@ -657,7 +657,7 @@ int main(int argc, char *argv[]) tabpending = 0; } move(y, x); - if (!exit_early && option_chgexit) { + if (!first_screen && !exit_early && option_chgexit) { #ifdef WITH_WATCH8BIT cchar_t oldc; in_wch(&oldc);