From c12f53090bd41dbb87279083bc442769cb0610f0 Mon Sep 17 00:00:00 2001 From: Denis Vlasenko Date: Fri, 6 Oct 2006 09:49:47 +0000 Subject: dnsd fix; option_mask32 added. dnsd needs more love. --- procps/top.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'procps') diff --git a/procps/top.c b/procps/top.c index ebfbcb8..be1c45f 100644 --- a/procps/top.c +++ b/procps/top.c @@ -34,8 +34,7 @@ typedef int (*cmp_t)(procps_status_t *P, procps_status_t *Q); static procps_status_t *top; /* Hehe */ static int ntop; -static unsigned option_mask; -#define OPT_BATCH_MODE (option_mask & 0x4) +#define OPT_BATCH_MODE (option_mask32 & 0x4) #ifdef CONFIG_FEATURE_USE_TERMIOS static int pid_sort(procps_status_t *P, procps_status_t *Q) @@ -398,11 +397,11 @@ int top_main(int argc, char **argv) /* do normal option parsing */ interval = 5; opt_complementary = "-"; - option_mask = getopt32(argc, argv, "d:n:b", + getopt32(argc, argv, "d:n:b", &sinterval, &siterations); - if (option_mask & 0x1) interval = atoi(sinterval); // -d - if (option_mask & 0x2) iterations = atoi(siterations); // -n - //if (option_mask & 0x4) // -b + if (option_mask32 & 0x1) interval = atoi(sinterval); // -d + if (option_mask32 & 0x2) iterations = atoi(siterations); // -n + //if (option_mask32 & 0x4) // -b /* change to /proc */ xchdir("/proc"); -- cgit v1.1