DF-1734 / fix.diff
diff --git a/sys/dev/raid/vinum/vinumconfig.c b/sys/dev/raid/vinum/vinumconfig.c --- a/sys/dev/raid/vinum/vinumconfig.c +++ b/sys/dev/raid/vinum/vinumconfig.c @@ -1728,7 +1728,7 @@ struct drive *drive = &DRIVE[driveno]; int sdno; - if ((driveno > vinum_conf.drives_allocated) /* not a valid drive */ + if ((driveno >= vinum_conf.drives_allocated) /* not a valid drive */ ||(drive->state == drive_unallocated)) { /* or nothing there */ ioctl_reply->error = EINVAL; strcpy(ioctl_reply->msg, "No such drive"); |