Re: Weird ecpg failures on buildfarm NetBSD members - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Weird ecpg failures on buildfarm NetBSD members
Date
Msg-id 3479.1184031887@sss.pgh.pa.us
Whole thread Raw
In response to Re: Weird ecpg failures on buildfarm NetBSD members  (Kris Jurka <books@ejurka.com>)
List pgsql-hackers
Kris Jurka <books@ejurka.com> writes:
> On Mon, 9 Jul 2007, Tom Lane wrote:
>> Today's puzzler for the curious:

> It turns out that this failure was caused by pulling in pg's own printf 
> implementation to the resulting ECPG program.

Hah!  Nice detective work, Kris.

> Calling printf("%.*f\n", -1, 14.7) results in "14" from pg_printf and 
> "14.700000" from NetBSD's.

So does this represent a bug or shortcoming in pg_printf?  A quick look
at the spec says that "A negative precision is taken as if the precision
were omitted", and rounding to int doesn't sound like the appropriate
behavior for bare %f.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Kris Jurka
Date:
Subject: Re: Weird ecpg failures on buildfarm NetBSD members
Next
From: "Shelby Epps"
Date:
Subject: Man Lebt nur einmal - probiers aus ! of clarity I think -- who've faced the