diff options
author | Artur Grabowski <art@cvs.openbsd.org> | 1999-08-16 19:06:16 +0000 |
---|---|---|
committer | Artur Grabowski <art@cvs.openbsd.org> | 1999-08-16 19:06:16 +0000 |
commit | 2839ace62fe1cfba56e74fda3c00955a64bcbb76 (patch) | |
tree | 2bd1c3e563e4b02d225b86c8b5c424dc60768c6e /usr.bin/vmstat/vmstat.c | |
parent | e298578c6f4bc5c991d43826dfa64e426cf75566 (diff) |
printf format fixes
Diffstat (limited to 'usr.bin/vmstat/vmstat.c')
-rw-r--r-- | usr.bin/vmstat/vmstat.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/usr.bin/vmstat/vmstat.c b/usr.bin/vmstat/vmstat.c index bb6ee7a1bfa..7caa671cdcc 100644 --- a/usr.bin/vmstat/vmstat.c +++ b/usr.bin/vmstat/vmstat.c @@ -1,5 +1,5 @@ /* $NetBSD: vmstat.c,v 1.29.4.1 1996/06/05 00:21:05 cgd Exp $ */ -/* $OpenBSD: vmstat.c,v 1.32 1999/07/17 22:11:15 art Exp $ */ +/* $OpenBSD: vmstat.c,v 1.33 1999/08/16 19:06:15 art Exp $ */ /* * Copyright (c) 1980, 1986, 1991, 1993 @@ -815,20 +815,20 @@ dointr() while (evptr) { if (kvm_read(kd, (long)evptr, (void *)&evcnt, sizeof evcnt) != sizeof evcnt) { - (void)fprintf(stderr, "vmstat: event chain trashed\n", + (void)fprintf(stderr, "vmstat: event chain trashed: %s\n", kvm_geterr(kd)); exit(1); } if (strcmp(evcnt.ev_name, "intr") == 0) { if (kvm_read(kd, (long)evcnt.ev_dev, (void *)&dev, sizeof dev) != sizeof dev) { - (void)fprintf(stderr, "vmstat: event chain trashed\n", + (void)fprintf(stderr, "vmstat: event chain trashed: %s\n", kvm_geterr(kd)); exit(1); } if (evcnt.ev_count) - (void)printf("%-14s %12ld %8ld\n", dev.dv_xname, - evcnt.ev_count, evcnt.ev_count / uptime); + (void)printf("%-14s %12d %8ld\n", dev.dv_xname, + evcnt.ev_count, (long)(evcnt.ev_count / uptime)); inttotal += evcnt.ev_count++; } evptr = evcnt.ev_list.tqe_next; |