#include <netdb.h>
#include <time.h>
#include <sys/stat.h>
+#include <sys/mount.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <rpc/auth.h>
#include "conn.h"
#include "xcommon.h"
+#include "mount_constants.h"
#include "nfs4_mount.h"
#include "nfs_mount.h"
#include "error.h"
return 0;
}
-int nfs4mount(const char *spec, const char *node, int *flags,
- char **extra_opts, char **mount_opts,
- int running_bg)
+int nfs4mount(const char *spec, const char *node, int flags,
+ char **extra_opts, int fake)
{
static struct nfs4_mount_data data;
static char hostdir[1024];
continue;
}
- *mount_opts = (char *) &data;
- /* clean up */
+ if (!fake) {
+ if (mount(spec, node, "nfs4",
+ flags & ~(MS_USER|MS_USERS), &data)) {
+ mount_error(spec, node, errno);
+ goto fail;
+ }
+ }
+
return 0;
fail: