]> git.proxmox.com Git - mirror_zfs.git/commit
Check for strlcat and strlcpy
authorBrian Behlendorf <behlendorf1@llnl.gov>
Wed, 12 Dec 2018 00:01:41 +0000 (16:01 -0800)
committerGitHub <noreply@github.com>
Wed, 12 Dec 2018 00:01:41 +0000 (16:01 -0800)
commit4b702901637ee0be1f654af38c86d0a68593f921
treedc8e39ec1bd01b6630e0e822b1a6077b346773f2
parenta48cd034c8df96ab751179b0c15bf84c6e178967
Check for strlcat and strlcpy

This partially reverts commit 8005ca4 by moving the strlcat()
and strlcpy() compatibility implementations back to their original
location.

In addition, these two functions were added to the AC_CHECK_FUNCS
macro. When these functions are available from the C library,
HAVE_STRLCAT and HAVE_STRLCPY will be defined and library version
used. Otherwise the compatibility version is built.

Reviewed-by: Sebastian Gottschall <s.gottschall@dd-wrt.com>
Reviewed-by: Alek Pinchuk <apinchuk@datto.com>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #8157
Closes #8202
config/user.m4
lib/libspl/Makefile.am
lib/libspl/include/string.h
lib/libspl/strlcat.c [new file with mode: 0644]
lib/libspl/strlcpy.c [new file with mode: 0644]
tests/zfs-tests/cmd/libzfs_input_check/Makefile.am