aboutsummaryrefslogtreecommitdiff
path: root/util-linux/mkfs_minix.c
diff options
context:
space:
mode:
authorGravatar Denys Vlasenko <vda.linux@googlemail.com>2009-08-02 20:18:29 +0200
committerGravatar Denys Vlasenko <vda.linux@googlemail.com>2009-08-02 20:18:29 +0200
commit4cd4eb43320de6ecccb3b69087daee325d0bbfc1 (patch)
tree44db952d0feea229c4359bd5a2f8dc59db5ee07d /util-linux/mkfs_minix.c
parent6a98f95373d60d48001299797f52b1f19c7ffecd (diff)
downloadbusybox-4cd4eb43320de6ecccb3b69087daee325d0bbfc1.tar.gz
busybox-4cd4eb43320de6ecccb3b69087daee325d0bbfc1.tar.bz2
apply post-1.14.2 patches
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'util-linux/mkfs_minix.c')
-rw-r--r--util-linux/mkfs_minix.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/util-linux/mkfs_minix.c b/util-linux/mkfs_minix.c
index 2666132f9..18512a395 100644
--- a/util-linux/mkfs_minix.c
+++ b/util-linux/mkfs_minix.c
@@ -624,7 +624,6 @@ static void setup_tables(void)
int mkfs_minix_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
int mkfs_minix_main(int argc UNUSED_PARAM, char **argv)
{
- struct mntent *mp;
unsigned opt;
char *tmp;
struct stat statbuf;
@@ -683,11 +682,8 @@ int mkfs_minix_main(int argc UNUSED_PARAM, char **argv)
G.total_blocks = 65535;
/* Check if it is mounted */
- mp = find_mount_point(G.device_name, NULL);
- if (mp && strcmp(G.device_name, mp->mnt_fsname) == 0)
- bb_error_msg_and_die("%s is mounted on %s; "
- "refusing to make a filesystem",
- G.device_name, mp->mnt_dir);
+ if (find_mount_point(G.device_name))
+ bb_error_msg_and_die("can't format mounted filesystem");
xmove_fd(xopen(G.device_name, O_RDWR), dev_fd);
if (fstat(dev_fd, &statbuf) < 0)