diff options
Diffstat (limited to 'cmd/zfs/zfs_main.c')
-rw-r--r-- | cmd/zfs/zfs_main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd/zfs/zfs_main.c b/cmd/zfs/zfs_main.c index cca52dbe7..301e2957e 100644 --- a/cmd/zfs/zfs_main.c +++ b/cmd/zfs/zfs_main.c @@ -3865,7 +3865,7 @@ zfs_do_send(int argc, char **argv) * Incremental source name begins with # or @. * Default to same fs as target. */ - (void) strncpy(frombuf, argv[0], sizeof (frombuf)); + (void) strlcpy(frombuf, argv[0], sizeof (frombuf)); cp = strchr(frombuf, '@'); if (cp != NULL) *cp = '\0'; @@ -6771,7 +6771,7 @@ zfs_do_bookmark(int argc, char **argv) *strchr(snapname, '#') = '\0'; (void) strlcat(snapname, argv[0], sizeof (snapname)); } else { - (void) strncpy(snapname, argv[0], sizeof (snapname)); + (void) strlcpy(snapname, argv[0], sizeof (snapname)); } zhp = zfs_open(g_zfs, snapname, ZFS_TYPE_SNAPSHOT); if (zhp == NULL) |