diff options
Diffstat (limited to 'miscutils/eject.c')
-rw-r--r-- | miscutils/eject.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/miscutils/eject.c b/miscutils/eject.c index 8864687e4..3f1d6ab44 100644 --- a/miscutils/eject.c +++ b/miscutils/eject.c | |||
@@ -48,13 +48,9 @@ extern int eject_main(int argc, char **argv) | |||
48 | if((m = find_mount_point(device, bb_path_mtab_file))) { | 48 | if((m = find_mount_point(device, bb_path_mtab_file))) { |
49 | if(umount(m->mnt_dir)) | 49 | if(umount(m->mnt_dir)) |
50 | bb_error_msg_and_die("Can't umount"); | 50 | bb_error_msg_and_die("Can't umount"); |
51 | #ifdef CONFIG_FEATURE_MTAB_SUPPORT | 51 | else if(ENABLE_FEATURE_MTAB_SUPPORT) erase_mtab(m->mnt_fsname); |
52 | else | ||
53 | erase_mtab(m->mnt_fsname); | ||
54 | #endif | ||
55 | } | 52 | } |
56 | if (ioctl(bb_xopen( device, | 53 | if (ioctl(bb_xopen( device, (O_RDONLY | O_NONBLOCK)), |
57 | (O_RDONLY | O_NONBLOCK)), | ||
58 | ( flags ? CDROMCLOSETRAY : CDROMEJECT))) | 54 | ( flags ? CDROMCLOSETRAY : CDROMEJECT))) |
59 | { | 55 | { |
60 | bb_perror_msg_and_die(device); | 56 | bb_perror_msg_and_die(device); |