Re: snprintf causes regression tests to fail - Mailing list pgsql-hackers

From Tom Lane
Subject Re: snprintf causes regression tests to fail
Date
Msg-id 6861.1109737284@sss.pgh.pa.us
Whole thread Raw
In response to Re: snprintf causes regression tests to fail  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: snprintf causes regression tests to fail
List pgsql-hackers
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Tom Lane wrote:
>> Does it help if you flip the order of the snprintf and vsnprintf
>> functions in snprintf.c?

> Yes, it fixes the problem and I have applied the reordering with a
> comment.

Fascinating.

> I will start working on fixing the large fmtpar allocations now.

Quite honestly, this code is not worth micro-optimizing because it
is fundamentally broken.  See my other comments in this thread.

Can we find a BSD-license implementation that follows the spec?

            regards, tom lane

pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: snprintf causes regression tests to fail
Next
From: Bruce Momjian
Date:
Subject: Re: snprintf causes regression tests to fail