diff options
author | grog <grog@FreeBSD.org> | 1999-03-31 08:44:20 +0000 |
---|---|---|
committer | grog <grog@FreeBSD.org> | 1999-03-31 08:44:20 +0000 |
commit | 08f9968437a18757aaacf119394e48c98a2f4c21 (patch) | |
tree | bef0ce70334dc42e34a1a7c5b9674e106c0db783 /sbin/vinum/commands.c | |
parent | 5f7149e9f2807fdd14272eeed32d0c3a84b2120c (diff) | |
download | FreeBSD-src-08f9968437a18757aaacf119394e48c98a2f4c21.zip FreeBSD-src-08f9968437a18757aaacf119394e48c98a2f4c21.tar.gz |
vinum_resetstats: Reset stats for drives correctly when recursing.
Diffstat (limited to 'sbin/vinum/commands.c')
-rw-r--r-- | sbin/vinum/commands.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sbin/vinum/commands.c b/sbin/vinum/commands.c index c516b62..4ead132 100644 --- a/sbin/vinum/commands.c +++ b/sbin/vinum/commands.c @@ -719,8 +719,10 @@ reset_sd_stats(int sdno, int recurse) if (ioctl(superdev, VINUM_RESETSTATS, &msg) < 0) { fprintf(stderr, "Can't reset stats for subdisk %d: %s\n", sdno, reply->msg); longjmp(command_fail, -1); - } else if (recurse) - reset_drive_stats(sd.driveno); + } else if (recurse) { + get_sd_info(&sd, sdno); /* get the info */ + reset_drive_stats(sd.driveno); /* and clear the drive */ + } } void |