summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGlenn L McGrath2001-05-07 01:51:24 +0000
committerGlenn L McGrath2001-05-07 01:51:24 +0000
commitcc0aa0f2d74901f3cdc87073f52020b98605cb79 (patch)
tree34be472c1d90a3fb3b00aeee1d56b109044012d5
parent1b6261944664beedf0e4e3e546635f0a809da41e (diff)
downloadbusybox-cc0aa0f2d74901f3cdc87073f52020b98605cb79.zip
busybox-cc0aa0f2d74901f3cdc87073f52020b98605cb79.tar.gz
Actually we dont need to check if the device is nfs as it wont be stat'ed
-rw-r--r--mount.c3
-rw-r--r--util-linux/mount.c3
2 files changed, 2 insertions, 4 deletions
diff --git a/mount.c b/mount.c
index e511b79..0295fab 100644
--- a/mount.c
+++ b/mount.c
@@ -385,8 +385,7 @@ extern int mount_main(int argc, char **argv)
if (optind < argc) {
/* if device is a filename get its real path */
- if ((strchr(argv[optind], ':') == NULL) &&
- (stat(argv[optind], &statbuf) == 0)) {
+ if (stat(argv[optind], &statbuf) == 0) {
realpath(argv[optind], device);
} else {
safe_strncpy(device, argv[optind], PATH_MAX);
diff --git a/util-linux/mount.c b/util-linux/mount.c
index e511b79..0295fab 100644
--- a/util-linux/mount.c
+++ b/util-linux/mount.c
@@ -385,8 +385,7 @@ extern int mount_main(int argc, char **argv)
if (optind < argc) {
/* if device is a filename get its real path */
- if ((strchr(argv[optind], ':') == NULL) &&
- (stat(argv[optind], &statbuf) == 0)) {
+ if (stat(argv[optind], &statbuf) == 0) {
realpath(argv[optind], device);
} else {
safe_strncpy(device, argv[optind], PATH_MAX);