]> granicus.if.org Git - procps-ng/commitdiff
top: some idiot broke 'idle' mode with u/U 'exclusion'
authorJim Warner <james.warner@comcast.net>
Thu, 21 Feb 2013 06:00:00 +0000 (00:00 -0600)
committerJaromir Capik <jcapik@redhat.com>
Wed, 27 Feb 2013 16:03:49 +0000 (17:03 +0100)
This patch fixes the single stinkin' source line which
was responsible for breaking the top idle-mode toggle.

Without this change, either 'u' or 'U' must be invoked
just once before the 'i' command would show something.

(yes, everything's perfectly justified once again but)
(i'm not very happy over the need for this damn patch)

Reference(s):
commit d04297843f14e399c699c29b4222b9c9d168c116

Signed-off-by: Jim Warner <james.warner@comcast.net>
top/top.c

index 267b7f1e97505d15688c28677a53107b3706c242..e254e202f265366afde30c76948b700c41f459e6 100644 (file)
--- a/top/top.c
+++ b/top/top.c
@@ -1316,7 +1316,7 @@ static const char *user_certify (WIN_t *q, const char *str, char typ) {
 static inline int user_matched (WIN_t *q, const proc_t *p) {
    switch(q->usrseltyp) {
       case 0:                                    // uid selection inactive
-         return q->usrselflg;
+         return 1;
       case 'U':                                  // match any uid
          if (p->ruid == q->usrseluid) return q->usrselflg;
          if (p->suid == q->usrseluid) return q->usrselflg;