This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [PATCH] Use __snprintf when available
- From: Steve Ellcey <sje at cup dot hp dot com>
- To: libstdc++ at gcc dot gnu dot org
- Date: Wed, 20 Mar 2002 08:45:29 -0800 (PST)
- Subject: Re: [PATCH] Use __snprintf when available
> 2- Autoconf issues, which seem to me really of two different kinds:
>
> * Are there any actual systems which make available a C99-conforming
> snprintf but which do not pass the tests for _GLIBCPP_USE_C99 enabled?
> I think Loren in principle is interested in supporting them.
I think HP-UX 11.0 (IA64 and PA) fits this situation. There is an
snprintf on the system but during config (of the library) I see:
checking for ISO C99 support in <math.h>... no
checking for ISO C99 support in <stdio.h>... yes
checking for ISO C99 support in <stdlib.h>... no
checking for additional ISO C99 support in <wchar.h>... no
checking for enabled ISO C99 support... no
checking for ISO C99 wchar_t support... no
I also ran a quick experiment and verified that if the buffer is too
small that snprintf returns -1. Am I correct in thinking that this is
not c99 conformant?
Steve Ellcey
sje@cup.hp.com