aboutsummaryrefslogtreecommitdiffstats
path: root/lib/libshare/smb.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libshare/smb.c')
-rw-r--r--lib/libshare/smb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libshare/smb.c b/lib/libshare/smb.c
index ffae5699c..4c2045dfd 100644
--- a/lib/libshare/smb.c
+++ b/lib/libshare/smb.c
@@ -219,7 +219,7 @@ smb_enable_share_one(const char *sharename, const char *sharepath)
int rc;
/* Support ZFS share name regexp '[[:alnum:]_-.: ]' */
- strncpy(name, sharename, sizeof (name));
+ strlcpy(name, sharename, sizeof (name));
name [sizeof (name)-1] = '\0';
pos = name;