bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug-gnulib] Re: strnlen.h needed?


From: Simon Josefsson
Subject: [bug-gnulib] Re: strnlen.h needed?
Date: Mon, 14 Mar 2005 17:46:56 +0100
User-agent: Gnus/5.110003 (No Gnus v0.3) Emacs/22.0.50 (gnu/linux)

Bruno Haible <address@hidden> writes:

> Simon Josefsson wrote:
>> +#if defined HAVE_DECL_STRNLEN && !HAVE_DECL_STRNLEN
>> +extern size_t strnlen(const char *s, size_t maxlen);
>> +#endif
>
> Are you aware of some platforms which have strnlen(), but don't declare it?

No; but that doesn't mean much.

> If yes, we need to move the AC_CHECK_DECLS(strnlen) from strndup.m4 to
> strnlen.m4. If no, we should drop the AC_CHECK_DECLS(strnlen).

What about conflicting prototypes?  It is not a standardized function,
after all, as far as I know.

I'm not sure what a good policy on these kind of questions should be,
in general.  Either we assume the best, and fix things when people
complain.  Or we assume the worst, and risk overdoing things.  I tend
to prefer the former, because it tend to leave a trail of when and
what systems had some problem.  My impression is that currently gnulib
do a little bit of both at times.  Which may be perfectly fine too.

Thanks.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]