X-Git-Url: https://git.decadent.org.uk/gitweb/?p=nfs-utils.git;a=blobdiff_plain;f=utils%2Fmount%2Fmount.c;h=06e2804f3cff43580a96888fab32f59290b73964;hp=a7539324122c68b1281ac9b127a9ed3b5add0a90;hb=632650fa1a0b358f9d8d617cfd115a334c4b9b66;hpb=58080798db321d025143df39c97f707ea994ba26 diff --git a/utils/mount/mount.c b/utils/mount/mount.c index a753932..06e2804 100644 --- a/utils/mount/mount.c +++ b/utils/mount/mount.c @@ -29,7 +29,6 @@ #include #include #include -#include #include #include #include @@ -45,8 +44,8 @@ #include "nfs4_mount.h" #include "mount.h" #include "error.h" -#include "network.h" #include "stropts.h" +#include "version.h" char *progname; int nfs_mount_data_version; @@ -146,24 +145,8 @@ static const struct opt_map opt_map[] = { { NULL, 0, 0, 0 } }; -#define MAKE_VERSION(p,q,r) (65536 * (p) + 256 * (q) + (r)) - static void parse_opts(const char *options, int *flags, char **extra_opts); -int linux_version_code(void) -{ - struct utsname my_utsname; - int p, q, r; - - if (uname(&my_utsname) == 0) { - p = atoi(strtok(my_utsname.release, ".")); - q = atoi(strtok(NULL, ".")); - r = atoi(strtok(NULL, ".")); - return MAKE_VERSION(p,q,r); - } - return 0; -} - /* * Choose the version of the nfs_mount_data structure that is appropriate * for the kernel that is doing the mount.