diff options
Diffstat (limited to 'util-linux/mkfs_minix.c')
-rw-r--r-- | util-linux/mkfs_minix.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/util-linux/mkfs_minix.c b/util-linux/mkfs_minix.c index 30bc9f12d..d9388b1d7 100644 --- a/util-linux/mkfs_minix.c +++ b/util-linux/mkfs_minix.c | |||
@@ -307,7 +307,7 @@ static inline int get_size(const char *file) | |||
307 | int fd; | 307 | int fd; |
308 | long size; | 308 | long size; |
309 | 309 | ||
310 | fd = bb_xopen(file, O_RDWR); | 310 | fd = bb_xopen3(file, O_RDWR, 0); |
311 | if (ioctl(fd, BLKGETSIZE, &size) >= 0) { | 311 | if (ioctl(fd, BLKGETSIZE, &size) >= 0) { |
312 | close(fd); | 312 | close(fd); |
313 | return (size * 512); | 313 | return (size * 512); |
@@ -820,7 +820,7 @@ goodbye: | |||
820 | tmp += dirsize; | 820 | tmp += dirsize; |
821 | *(short *) tmp = 2; | 821 | *(short *) tmp = 2; |
822 | strcpy(tmp + 2, ".badblocks"); | 822 | strcpy(tmp + 2, ".badblocks"); |
823 | DEV = bb_xopen(device_name, O_RDWR); | 823 | DEV = bb_xopen3(device_name, O_RDWR, 0); |
824 | if (fstat(DEV, &statbuf) < 0) | 824 | if (fstat(DEV, &statbuf) < 0) |
825 | bb_error_msg_and_die("unable to stat %s", device_name); | 825 | bb_error_msg_and_die("unable to stat %s", device_name); |
826 | if (!S_ISBLK(statbuf.st_mode)) | 826 | if (!S_ISBLK(statbuf.st_mode)) |