X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=utils%2Fmount%2Fmount.c;h=d7271a1c32757b3cadc451e9f093f9aec672dc44;hb=331c2ca949d5b4b4d18d0aca90afb8ae9475bcd6;hp=839a3296214ac654aa5738bc33f004ba5003dc31;hpb=00511ee5c97793fa8bf3f463ac07cbb4029ca149;p=nfs-utils.git diff --git a/utils/mount/mount.c b/utils/mount/mount.c index 839a329..d7271a1 100644 --- a/utils/mount/mount.c +++ b/utils/mount/mount.c @@ -18,7 +18,10 @@ * */ -#include "config.h" +#ifdef HAVE_CONFIG_H +#include +#endif + #include #include #include @@ -536,6 +539,12 @@ int main(int argc, char *argv[]) mnt_err = EX_USAGE; goto out; } + + if (geteuid() != 0) { + nfs_error(_("%s: not installed setuid - " + "\"user\" NFS mounts not supported."), progname); + exit(EX_FAIL); + } } if (chk_mountpoint(mount_point)) {