aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndriy Gapon <avg@FreeBSD.org>2019-10-16 06:09:00 +0000
committerAndriy Gapon <avg@FreeBSD.org>2019-10-16 06:09:00 +0000
commitb399ca755a71c0de0c7963b509a15260aaa07a99 (patch)
treed6ba213e69e841821a1ad7c56196b8e3e992839c
parentfba547735cd54072b904c13d93cc23f5d18d2dac (diff)
parentb75b64ae4b5f90dc68ba6e65ef683d62650d40ba (diff)
downloadsrc-b399ca755a71c0de0c7963b509a15260aaa07a99.tar.gz
src-b399ca755a71c0de0c7963b509a15260aaa07a99.zip
MFV r353608: 10165 libzpool: passing argument 1 to restrict-qualified parameter
illumos/illumos-gate@f91fcf59ac2fd04f1816f3dcbc69a46d44276a65 https://github.com/illumos/illumos-gate/commit/f91fcf59ac2fd04f1816f3dcbc69a46d44276a65 https://www.illumos.org/issues/10165 Author: Toomas Soome <tsoome@me.com> MFC after: 10 days
Notes
Notes: svn path=/head/; revision=353609
-rw-r--r--sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c
index 03cf52cf6b06..06a04474e3cd 100644
--- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c
+++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c
@@ -2196,7 +2196,10 @@ dsl_get_mountpoint(dsl_dataset_t *ds, const char *dsname, char *value,
return (error);
}
- /* Process the dsname and source to find the full mountpoint string */
+ /*
+ * Process the dsname and source to find the full mountpoint string.
+ * Can be skipped for 'legacy' or 'none'.
+ */
if (value[0] == '/') {
char *buf = kmem_alloc(ZAP_MAXVALUELEN, KM_SLEEP);
char *root = buf;
@@ -2247,10 +2250,8 @@ dsl_get_mountpoint(dsl_dataset_t *ds, const char *dsname, char *value,
relpath);
}
kmem_free(buf, ZAP_MAXVALUELEN);
- } else {
- /* 'legacy' or 'none' */
- (void) snprintf(value, ZAP_MAXVALUELEN, "%s", value);
}
+
return (0);
}