summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorMarcel Telka <[email protected]>2016-01-10 23:35:29 +0100
committerBrian Behlendorf <[email protected]>2016-01-12 14:27:50 -0800
commit7ea4f88f8f94f6071f8533e85555139c81ddd647 (patch)
tree889888631777abd1faa1c740089910b49376a46f /lib
parentd25b4497b7c7c209cbe28d31189bd7b2489b3d2f (diff)
Illumos 6280 - libzfs: unshare_one() could fail with EZFS_SHARENFSFAILED
6280 libzfs: unshare_one() could fail with EZFS_SHARENFSFAILED Reviewed by: Toomas Soome <[email protected]> Reviewed by: Dan McDonald <[email protected]> Reviewed by: Matthew Ahrens <[email protected]> Approved by: Gordon Ross <[email protected]> References: https://www.illumos.org/issues/6280 https://github.com/illumos/illumos-gate/commit/d1672ef Ported-by: kernelOfTruth [email protected] Signed-off-by: Brian Behlendorf <[email protected]>
Diffstat (limited to 'lib')
-rw-r--r--lib/libzfs/libzfs_mount.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libzfs/libzfs_mount.c b/lib/libzfs/libzfs_mount.c
index c01ec105e..41ab86131 100644
--- a/lib/libzfs/libzfs_mount.c
+++ b/lib/libzfs/libzfs_mount.c
@@ -20,6 +20,7 @@
*/
/*
+ * Copyright 2015 Nexenta Systems, Inc. All rights reserved.
* Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
*/
@@ -857,7 +858,7 @@ unshare_one(libzfs_handle_t *hdl, const char *name, const char *mountpoint,
/* make sure libshare initialized */
if ((err = zfs_init_libshare(hdl, SA_INIT_SHARE_API)) != SA_OK) {
free(mntpt); /* don't need the copy anymore */
- return (zfs_error_fmt(hdl, EZFS_SHARENFSFAILED,
+ return (zfs_error_fmt(hdl, EZFS_UNSHARENFSFAILED,
dgettext(TEXT_DOMAIN, "cannot unshare '%s': %s"),
name, sa_errorstr(err)));
}