return (data);
}
-#ifdef HAVE_ZPL
static char *
safe_strdup(char *str)
{
return (dupstr);
}
-#endif /* HAVE_ZPL */
/*
* Callback routine that will print out information for each of
#define PROGRESS_DELAY 2 /* seconds */
-#ifdef HAVE_ZPL
static char *pt_reverse = "\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b";
static time_t pt_begin;
static char *pt_header = NULL;
free(pt_header);
pt_header = NULL;
}
-#endif /* HAVE_ZPL */
/*
* zfs clone [-p] [-o prop=value] ... <snap> <fs | vol>
ret = zfs_clone(zhp, argv[1], props);
/* create the mountpoint if necessary */
-#ifdef HAVE_ZPL
if (ret == 0) {
zfs_handle_t *clone;
zfs_close(clone);
}
}
-#endif /* HAVE_ZPL */
zfs_close(zhp);
nvlist_free(props);
* verbose error message to let the user know that their filesystem was
* in fact created, even if we failed to mount or share it.
*/
-#ifdef HAVE_ZPL
if (canmount == ZFS_CANMOUNT_ON) {
if (zfs_mount(zhp, NULL, 0) != 0) {
(void) fprintf(stderr, gettext("filesystem "
ret = 1;
}
}
-#endif /* HAVE_ZPL */
error:
if (zhp)
* 'cb_dependent' is set, then this is a dependent and we should report it
* without checking the transaction group.
*/
-#ifdef HAVE_ZPL
static int
rollback_check(zfs_handle_t *zhp, void *data)
{
zfs_close(zhp);
return (0);
}
-#endif /* HAVE_ZPL */
static int
zfs_do_rollback(int argc, char **argv)
{
-#ifdef HAVE_ZPL
int ret;
int c;
boolean_t force = B_FALSE;
return (0);
else
return (1);
-#else
- return ENOSYS;
-#endif /*HAVE_ZPL*/
}
/*
#define SPINNER_TIME 3 /* seconds */
#define MOUNT_TIME 5 /* seconds */
-#ifdef HAVE_ZPL
static int
get_one_dataset(zfs_handle_t *zhp, void *data)
{
return (ret);
}
-#endif /* HAVE_ZPL */
/*
* zfs mount -a [nfs]
static int
zfs_do_mount(int argc, char **argv)
{
-#ifdef HAVE_ZPL
return (share_mount(OP_MOUNT, argc, argv));
-#else
- return ENOSYS;
-#endif /* HAVE_ZPL */
}
/*
static int
zfs_do_share(int argc, char **argv)
{
-#ifdef HAVE_ZPL
return (share_mount(OP_SHARE, argc, argv));
-#else
- return ENOSYS;
-#endif /* HAVE_ZPL */
}
-#ifdef HAVE_ZPL
typedef struct unshare_unmount_node {
zfs_handle_t *un_zhp;
char *un_mountp;
return (ret);
}
-#endif /* HAVE_ZPL */
/*
* zfs unmount -a
static int
zfs_do_unmount(int argc, char **argv)
{
-#ifdef HAVE_ZPL
return (unshare_unmount(OP_MOUNT, argc, argv));
-#else
- return ENOSYS;
-#endif /* HAVE_ZPL */
}
/*
static int
zfs_do_unshare(int argc, char **argv)
{
-#ifdef HAVE_ZPL
return (unshare_unmount(OP_SHARE, argc, argv));
-#else
- return ENOSYS;
-#endif /* HAVE_ZPL */
}
/* ARGSUSED */
#endif
/* Valid options not found in mount(8) */
{ MNTOPT_BIND, MS_BIND },
+#ifdef MS_REC
{ MNTOPT_RBIND, MS_BIND|MS_REC },
+#endif
{ MNTOPT_COMMENT, MS_COMMENT },
{ MNTOPT_BOOTWAIT, MS_COMMENT },
{ MNTOPT_NOBOOTWAIT, MS_COMMENT },