summaryrefslogtreecommitdiff
path: root/util-linux/mkfs_vfat.c
diff options
context:
space:
mode:
Diffstat (limited to 'util-linux/mkfs_vfat.c')
-rw-r--r--util-linux/mkfs_vfat.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/util-linux/mkfs_vfat.c b/util-linux/mkfs_vfat.c
index 211e67e..45760f7 100644
--- a/util-linux/mkfs_vfat.c
+++ b/util-linux/mkfs_vfat.c
@@ -245,8 +245,7 @@ int mkfs_vfat_main(int argc UNUSED_PARAM, char **argv)
volume_id = time(NULL);
dev = xopen(device_name, O_RDWR);
- if (fstat(dev, &st) < 0)
- bb_simple_perror_msg_and_die(device_name);
+ xfstat(dev, &st, device_name);
//
// Get image size and sector size