`Hiding' libc symbols
Andrey A. Chernov
ache at nagual.pp.ru
Thu May 1 09:25:32 PDT 2003
On Thu, May 01, 2003 at 20:09:44 +0400, Andrey A. Chernov wrote:
> On Thu, May 01, 2003 at 11:01:19 -0500, Jacques A. Vidrine wrote:
> > No, you are mistaken.
> >
> > namespace.h
> >
> > 39 /*
> > 40 * ISO C (C90) section. Most names in libc aren't in ISO C, so they
> > 41 * should be here. Most aren't here...
> > 42 */
> > 43 #define err _err
> > 44 #define warn _warn
> > 45 #define nsdispatch _nsdispatch
> > 46 #define strlcat _strlcat
> > 47 #define strlcpy _strlcpy
> >
> > The comment dates back to 2001.
>
> And you are mistaken to add str* functions here. While the comment is true
> for err, warn etc. it is not true for standard-reserved str* prefix.
Just to note: we already have this precedent happens with strcasestr()
function, not covered by standards. Some ports define their own
strcasestr(). We decide to fix ports instead of libc hacking.
And now we have two different ways of handling that case, one for
strcasestr() and another for strlcat(). Where is logic?
More information about the freebsd-arch
mailing list