diff options
author | наб <[email protected]> | 2022-02-25 14:26:54 +0100 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2022-03-15 15:13:42 -0700 |
commit | 861166b02701dfc8f63a105bd32758e806c84fd7 (patch) | |
tree | 1f9341513470b4615ca340c40ad087101c7dcf24 /module/os/linux/zfs/zfs_znode.c | |
parent | 1d77d62f5a77cab85d4b98ecf72a9838f70d6bf1 (diff) |
Remove bcopy(), bzero(), bcmp()
bcopy() has a confusing argument order and is actually a move, not a
copy; they're all deprecated since POSIX.1-2001 and removed in -2008,
and we shim them out to mem*() on Linux anyway
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Ahelenia Ziemiańska <[email protected]>
Closes #12996
Diffstat (limited to 'module/os/linux/zfs/zfs_znode.c')
-rw-r--r-- | module/os/linux/zfs/zfs_znode.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/module/os/linux/zfs/zfs_znode.c b/module/os/linux/zfs/zfs_znode.c index d65d75312..b76e65d16 100644 --- a/module/os/linux/zfs/zfs_znode.c +++ b/module/os/linux/zfs/zfs_znode.c @@ -1581,7 +1581,7 @@ zfs_zero_partial_page(znode_t *zp, uint64_t start, uint64_t len) flush_dcache_page(pp); pb = kmap(pp); - bzero(pb + off, len); + memset(pb + off, 0, len); kunmap(pp); if (mapping_writably_mapped(mp)) @@ -2153,7 +2153,7 @@ zfs_obj_to_path_impl(objset_t *osp, uint64_t obj, sa_handle_t *hdl, component[0] = '/'; if (is_xattrdir) { - (void) sprintf(component + 1, "<xattrdir>"); + strcpy(component + 1, "<xattrdir>"); } else { error = zap_value_search(osp, pobj, obj, ZFS_DIRENT_OBJ(-1ULL), component + 1); @@ -2164,7 +2164,7 @@ zfs_obj_to_path_impl(objset_t *osp, uint64_t obj, sa_handle_t *hdl, complen = strlen(component); path -= complen; ASSERT(path >= buf); - bcopy(component, path, complen); + memcpy(path, component, complen); obj = pobj; if (sa_hdl != hdl) { |