Complete.Org: Mailing Lists: Archives: freeciv-dev: August 1999:
[Freeciv-Dev] Re: snprintf, again
Home

[Freeciv-Dev] Re: snprintf, again

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: freeciv-dev@xxxxxxxxxxx
Cc: freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: snprintf, again
From: sebauer@xxxxxxxxxxx (Sebastian Bauer)
Date: Thu, 26 Aug 1999 11:37:29 +0100

Hello

>> I am curious though, what platforms don't have snprintf, and which have
>> vsnprintf but no snprintf?
> well, codewarior has the folowing variations in the stdio header
> fprintf
> printf
> sprintf
> vfprintf
> vprintf
> vsprintf

On the amiga (v)snprintf is avaible when using GNU C together with
ixemul.library.

It's not availble in the compiler I use for the ixemul free version
of freeciv. But it should be no problem for me to write an own
vsnprintf (which supports only those things needed for freeciv).
Maybe I also can take the one which is in the ixemul.library.
But I haven't looked in this source yet.

So I think (v)snprintf should be used where avaiable. If it is
not avaiable on a platform we can use David's idea with the buffer.
I really can't imagine that someone needs a string longer than
64kb.
Actually freeciv does sprintf on much smaller buffers and works fine,
so it cannot work worser with a 64kb or eveb higher buffer ;-)

bye,
Sebastian Bauer


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