Re: [HACKERS] snprintf causes regression tests

Bruce Momjian <[email protected]> Mon, 14 Mar 2005 14:39:19 -0500 (EST)
Newsgroups gmane.comp.db.postgresql.devel.win32,gmane.comp.db.postgresql.devel.general
Message-ID <[email protected]>
Tom Lane wrote:
> Bruce Momjian <[email protected]> writes:
> > I am wondering if we should just process long long args and %$ args,
> > and pass everything else to the native snprintf.
> 
> AFAICS this is a non-starter --- how will you construct the call to
> snprintf?  Or even vsnprintf?  C doesn't provide the tools you need
> to make it happen.

Couldn't you spin through the varargs and reconstruct a new one?
Is there no way to create a va_arg va_list structure in C?

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  [email protected]               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster