#include <unistd.h>
#include <sys/types.h>
+#include <sys/stat.h>
#include <stdio.h>
#include <string.h>
#include <errno.h>
return result;
}
-void mount_usage(void)
+static void mount_usage(void)
{
printf(_("usage: %s remotetarget dir [-rvVwfnsih] [-o nfsoptions]\n"),
progname);
printf(_("\tnfsoptions\tRefer to mount.nfs(8) or nfs(5)\n\n"));
}
-static void parse_opt(const char *opt, int *mask, char *extra_opts, int len)
+static void parse_opt(const char *opt, int *mask, char *extra_opts, size_t len)
{
const struct opt_map *om;
if (options != NULL) {
char *opts = xstrdup(options);
char *opt, *p;
- int len = strlen(opts) + 1; /* include room for a null */
+ size_t len = strlen(opts) + 1; /* include room for a null */
int open_quote = 0;
*extra_opts = xmalloc(len);
spec = argv[1];
mount_point = argv[2];
- mount_config_init();
+ mount_config_init(progname);
argv[2] = argv[0]; /* so that getopt error messages are correct */
while ((c = getopt_long(argc - 2, argv + 2, "rvVwfno:hs",
if (mnt_err == EX_BG) {
printf(_("%s: backgrounding \"%s\"\n"),
progname, spec);
+ printf(_("%s: mount options: \"%s\"\n"),
+ progname, extra_opts);
+
fflush(stdout);
/*