Don't use curses until initialized.

This commit is contained in:
Poul-Henning Kamp 1995-03-12 01:47:08 +00:00
parent 3d2a8cf3d9
commit c3f4fea40c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=7011

View File

@ -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);