add Sun compatibility ala assuming NFS when spec contains ':' or '@'
authorKirk McKusick <mckusick@ucbvax.Berkeley.EDU>
Mon, 4 Jun 1990 02:55:14 +0000 (18:55 -0800)
committerKirk McKusick <mckusick@ucbvax.Berkeley.EDU>
Mon, 4 Jun 1990 02:55:14 +0000 (18:55 -0800)
SCCS-vsn: sbin/mount/mount.c 5.38

usr/src/sbin/mount/mount.c

index 738b4e7..f854908 100644 (file)
@@ -12,7 +12,7 @@ char copyright[] =
 #endif /* not lint */
 
 #ifndef lint
 #endif /* not lint */
 
 #ifndef lint
-static char sccsid[] = "@(#)mount.c    5.37 (Berkeley) %G%";
+static char sccsid[] = "@(#)mount.c    5.38 (Berkeley) %G%";
 #endif /* not lint */
 
 #include "pathnames.h"
 #endif /* not lint */
 
 #include "pathnames.h"
@@ -202,6 +202,14 @@ main(argc, argv, arge)
                usage();
                ret = 1;
        } else {
                usage();
                ret = 1;
        } else {
+               /*
+                * If -t flag has not been specified, and spec
+                * contains either a ':' or a '@' then assume that
+                * an NFS filesystem is being specified ala Sun.
+                */
+               if (vfslist == (char **)0 &&
+                   (index(argv[0], ':') || index(argv[0], '@')))
+                       mnttype = MOUNT_NFS;
                ret = mountfs(argv[0], argv[1], updateflg, type, options,
                    (char *)NULL);
        }
                ret = mountfs(argv[0], argv[1], updateflg, type, options,
                    (char *)NULL);
        }