diff options
Diffstat (limited to 'mount.c')
-rw-r--r-- | mount.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -405,14 +405,14 @@ extern int mount_main(int argc, char **argv) | |||
405 | argv++; | 405 | argv++; |
406 | } | 406 | } |
407 | 407 | ||
408 | if (device == NULL && directory == NULL) | ||
409 | goto goodbye; | ||
410 | |||
411 | if (all == TRUE || directory == NULL) { | 408 | if (all == TRUE || directory == NULL) { |
412 | struct mntent *m; | 409 | struct mntent *m; |
413 | FILE *f = setmntent("/etc/fstab", "r"); | 410 | FILE *f = setmntent("/etc/fstab", "r"); |
414 | fstabmount = TRUE; | 411 | fstabmount = TRUE; |
415 | 412 | ||
413 | if (all == FALSE && device == NULL) | ||
414 | goto goodbye; | ||
415 | |||
416 | if (f == NULL) | 416 | if (f == NULL) |
417 | perror_msg_and_die( "\nCannot read /etc/fstab"); | 417 | perror_msg_and_die( "\nCannot read /etc/fstab"); |
418 | 418 | ||