mbrtowc: Work around a Solaris 7 bug.
authorBruno Haible <bruno@clisp.org>
Mon, 27 Dec 2010 13:28:11 +0000 (14:28 +0100)
committerBruno Haible <bruno@clisp.org>
Mon, 27 Dec 2010 13:29:25 +0000 (14:29 +0100)
commit777cb5e9cb12fd56d998f2eaa9348dd4e0078cac
tree860a9b97679852b6ffd2d6ad06d41d76a79bb0ed
parent94879b67cd7832e8a60df732a23fb764f2a15075
mbrtowc: Work around a Solaris 7 bug.

* m4/mbrtowc.m4 (gl_MBRTOWC_NULL_ARG1): New macro.
(gl_MBRTOWC_NULL_ARG2): Renamed from gl_MBRTOWC_NULL_ARG.
(gl_FUNC_MBRTOWC): Update. Define MBRTOWC_NULL_ARG2_BUG instead of
MBRTOWC_NULL_ARG_BUG. Invoke gl_MBRTOWC_NULL_ARG1 and define
MBRTOWC_NULL_ARG1_BUG.
* lib/mbrtowc.c (rpl_mbrtowc): Use MBRTOWC_NULL_ARG2_BUG instead of
MBRTOWC_NULL_ARG_BUG. Handle MBRTOWC_NULL_ARG1_BUG.
* tests/test-mbrtowc.c (main): Test support of a NULL first argument.
* doc/posix-functions/mbrtowc.texi: Mention the Solaris 7 bug.
ChangeLog
doc/posix-functions/mbrtowc.texi
lib/mbrtowc.c
m4/mbrtowc.m4
tests/test-mbrtowc.c