]> Savannah Git Hosting - gnulib.git/commit
string: Fix "mismatched allocation function" warnings regarding strndup.
authorBruno Haible <bruno@clisp.org>
Thu, 10 Feb 2022 01:44:14 +0000 (02:44 +0100)
committerBruno Haible <bruno@clisp.org>
Wed, 31 Aug 2022 22:46:55 +0000 (00:46 +0200)
commitb7b0944f5200b76811e2c1fb5ebf272704d5bcee
tree489a2f8e0a5d75daa2d42e268f5254e9b45e90dd
parentecf81e780e5b1103a816d7a835f0414ce8f2711b
string: Fix "mismatched allocation function" warnings regarding strndup.

* lib/string.in.h (strndup): Mark with _GL_ATTRIBUTE_MALLOC and
_GL_ATTRIBUTE_DEALLOC_FREE. For GCC >= 11: Declare also when the
platform already declares the function or when the module 'strndup' is
not in use.
ChangeLog
lib/string.in.h