vinum_resetstats: Reset stats for drives correctly when recursing.

This commit is contained in:
Greg Lehey 1999-03-31 08:44:20 +00:00
parent 95869fbbd3
commit 4bd1924ddf

View File

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