On Mon, Dec 05, 2005 at 04:35:31PM -0500, Bruce Momjian wrote:
>
> but it seems this is some BSD'ism that we don't need to support if the
> standard doesn't say so.
I think the Linux manpage is more informative about this:
The functions snprintf and vsnprintf do not write more than
Kurt Roeckx <[EMAIL PROTECTED]> writes:
> Concerning the return value of snprintf(), the SUSv2 and the C99 stan-
> dard contradict each other:
Is that where the problem comes from?
Anyway, I've added some text to snprintf.c explaining what we do. Since
the calling code has to be prepa
Bruce Momjian writes:
> Upon successful completion snprintf() and vsnprintf() return the number
> of characters that would have been written to a sufficiently sized str,
> excluding the terminating NUL character.
> but it seems this is some BSD'ism that we don't need to support
Tom Lane wrote:
> Bruce Momjian writes:
> > Tom, did you implement this functionality in *printf?
> > The size may be given as zero to find out how many characters are
> > needed; in this case, the str argument is ignored. Sprintf() and
> > vsprintf() effectively assume an infinite siz
Bruce Momjian writes:
> Tom, did you implement this functionality in *printf?
> The size may be given as zero to find out how many characters are
> needed; in this case, the str argument is ignored. Sprintf() and
> vsprintf() effectively assume an infinite size.
Where do you rea
Tom, did you implement this functionality in *printf?
The size may be given as zero to find out how many characters are
needed; in this case, the str argument is ignored. Sprintf() and
vsprintf() effectively assume an infinite size.
Looking at the code it doesn't seem supp