Actually we dont need to check if the device is nfs as it wont be stat'ed
authorGlenn L McGrath <bug1@ihug.co.nz>
Mon, 7 May 2001 01:51:24 +0000 (01:51 -0000)
committerGlenn L McGrath <bug1@ihug.co.nz>
Mon, 7 May 2001 01:51:24 +0000 (01:51 -0000)
mount.c
util-linux/mount.c

diff --git a/mount.c b/mount.c
index e511b798b9e78c89ca520d418c8bbb2ebd17dfdf..0295fabc69896c46ef48372da3676399eb98428b 100644 (file)
--- 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);
index e511b798b9e78c89ca520d418c8bbb2ebd17dfdf..0295fabc69896c46ef48372da3676399eb98428b 100644 (file)
@@ -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);