Mercurial > hg > octave-lyh > gnulib-hg
changeset 7598:936bef048010
Fix clash of strncasecmp prototypes in C++ mode.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Wed, 01 Nov 2006 20:48:47 +0000 |
parents | 99135a4b8955 |
children | 352da45c182e |
files | ChangeLog lib/strcase.h m4/strcase.m4 |
diffstat | 3 files changed, 9 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2006-11-01 Bruno Haible <bruno@clisp.org> + + * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is + already declared in <string.h>. + * lib/strcase.h (strncasecmp): Don't declare it if yes. + 2006-11-01 Bruno Haible <bruno@clisp.org> * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
--- a/lib/strcase.h +++ b/lib/strcase.h @@ -43,7 +43,9 @@ returning less than, equal to or greater than zero if S1 is lexicographically less than, equal to or greater than S2. Note: This function can not work correctly in multibyte locales. */ +#if ! HAVE_DECL_STRNCASECMP extern int strncasecmp (const char *s1, const char *s2, size_t n); +#endif #ifdef __cplusplus