diff options
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/systat/main.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/usr.bin/systat/main.c b/usr.bin/systat/main.c index 07975f3..69523c9 100644 --- a/usr.bin/systat/main.c +++ b/usr.bin/systat/main.c @@ -111,14 +111,6 @@ main(argc, argv) error("%s", errbuf); exit(1); } - if (kvm_nlist(kd, namelist)) { - nlisterr(namelist); - exit(1); - } - if (namelist[X_FIRST].n_type == 0) { - fprintf(stderr, "couldn't read namelist.\n"); - exit(1); - } signal(SIGINT, die); signal(SIGQUIT, die); signal(SIGTERM, die); @@ -141,6 +133,14 @@ main(argc, argv) fprintf(stderr, "Couldn't set up load average window.\n"); die(0); } + if (kvm_nlist(kd, namelist)) { + nlisterr(namelist); + exit(1); + } + if (namelist[X_FIRST].n_type == 0) { + fprintf(stderr, "couldn't read namelist.\n"); + exit(1); + } gethostname(hostname, sizeof (hostname)); NREAD(X_HZ, &hz, LONG); NREAD(X_STATHZ, &stathz, LONG); |