summaryrefslogtreecommitdiffstats
path: root/sbin/fsck_ffs/setup.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>1999-11-27 20:02:27 +0000
committerphk <phk@FreeBSD.org>1999-11-27 20:02:27 +0000
commit44eb44a9e89f713e7927093b25547d6532b4b728 (patch)
tree31508c495c89229d2593305b119b325ce4b6716c /sbin/fsck_ffs/setup.c
parent9fc872877e2cdc38e087f03f84b5fd16fa9fe726 (diff)
downloadFreeBSD-src-44eb44a9e89f713e7927093b25547d6532b4b728.zip
FreeBSD-src-44eb44a9e89f713e7927093b25547d6532b4b728.tar.gz
Make fsck even more char/blk dev tolerant.
Diffstat (limited to 'sbin/fsck_ffs/setup.c')
-rw-r--r--sbin/fsck_ffs/setup.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sbin/fsck_ffs/setup.c b/sbin/fsck_ffs/setup.c
index 7444d375..0df8e98 100644
--- a/sbin/fsck_ffs/setup.c
+++ b/sbin/fsck_ffs/setup.c
@@ -87,8 +87,9 @@ setup(dev)
printf("Can't stat %s: %s\n", dev, strerror(errno));
return (0);
}
- if ((statb.st_mode & S_IFMT) != S_IFCHR) {
- pfatal("%s is not a character device", dev);
+ if ((statb.st_mode & S_IFMT) != S_IFCHR &&
+ (statb.st_mode & S_IFMT) != S_IFBLK) {
+ pfatal("%s is not a disk device", dev);
if (reply("CONTINUE") == 0)
return (0);
}
OpenPOWER on IntegriCloud