From:
Nicolai Tufar <ntufar(at)gmail(dot)com>
To:
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc:
Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>,Magnus Hagander <mha(at)sollentuna(dot)net>,PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>
Subject:
Re: [pgsql-hackers-win32] [HACKERS] snprintf causes regression tests to fail
Date:
2005-03-02 06:06:35
Message-ID:
d80929390503012206557ba543@mail.gmail.com (view raw or flat )
Thread:
2005-03-02 01:55:11 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-02 02:32:39 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-02 02:38:55 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-02 03:23:18 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-02 04:21:24 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-02 04:23:08 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-02 04:31:19 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-02 05:22:14 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-02 05:38:59 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-02 06:06:35 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-02 06:33:05 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-02 15:41:00 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-02 16:00:53 from pgsql(at)mohawksoft(dot)com
2005-03-02 18:21:47 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-02 21:38:28 from pgsql(at)mohawksoft(dot)com
2005-03-03 00:03:02 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-09 12:40:24 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-09 15:38:27 from pgsql(at)mohawksoft(dot)com
2005-03-10 03:51:27 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-10 19:22:13 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-10 21:26:47 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-10 22:43:48 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-11 16:21:23 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-10 23:55:06 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-11 00:21:41 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-11 01:29:49 from pgsql(at)mohawksoft(dot)com
2005-03-11 03:58:27 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-11 16:18:07 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-11 17:02:29 from pgsql(at)mohawksoft(dot)com
2005-03-11 17:14:26 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-11 17:23:36 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-11 17:37:24 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-11 17:44:19 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-11 04:10:12 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-11 05:58:11 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-11 06:14:31 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-11 06:41:39 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-11 23:58:15 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-12 15:00:14 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-16 06:00:21 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-16 11:36:50 from Nicolai Tufar <ntufar(at)gmail(dot)com>
2005-03-16 15:07:28 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-16 21:28:07 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-20 05:11:18 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-20 06:49:37 from Greg Stark <gsstark(at)mit(dot)edu>
2005-03-20 18:23:58 from Andrew Dunstan <andrew(at)dunslane(dot)net>
2005-05-05 21:03:11 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-14 18:55:16 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-14 19:19:14 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-14 19:39:19 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-14 19:41:01 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2005-03-10 21:19:33 from Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
2005-03-02 12:09:37 from pgsql(at)mohawksoft(dot)com
Lists:
pgsql-hackers pgsql-hackers-win32 pgsql-patches
Tom lane wrote:
> With CVS-tip snprintf I get
> result = '3 42'
> result = '3 3505'
I get similar results:
result = '3 42'
result = '9e-313 1413754129'
Now I agree with you, it is fundamentally broken.
We need to replace this implementation.
Bruce Momjian wrote:
> I can confirm that using "%I64d" for the printf format allows the
> regression tests to pass for int8.
But snprintf.c code does not support "%I64d" construct. It must
be picking OS's vsnprintf()
Bruce Momjian wrote:
> I think FreeBSD does.
I started with FreeBSD's vsnprintf() at first
but was set back by it's complexity and decided to
modify the port/snprintf.c code. Now would you like me
to incorporate FreeBSD's one into the code.
Give me a week and I will come with the patch.
Best regards,
Nicolai Tufar
In response to
Responses
pgsql-hackers by date
Next :From: Tom LaneDate: 2005-03-02 06:33:05
Subject : Re: [pgsql-hackers-win32] [HACKERS] snprintf causes regression tests to fail
Previous :From : Tom LaneDate : 2005-03-02 05:38:59
Subject : Re: [pgsql-hackers-win32] [HACKERS] snprintf causes regression tests to fail
pgsql-patches by date
Next :From: Tom LaneDate: 2005-03-02 06:33:05
Subject : Re: [pgsql-hackers-win32] [HACKERS] snprintf causes regression tests to fail
Previous :From : Tom LaneDate : 2005-03-02 05:38:59
Subject : Re: [pgsql-hackers-win32] [HACKERS] snprintf causes regression tests to fail
pgsql-hackers-win32 by date
Next :From: Tom LaneDate: 2005-03-02 06:33:05
Subject : Re: [pgsql-hackers-win32] [HACKERS] snprintf causes regression tests to fail
Previous :From : Tom LaneDate : 2005-03-02 05:38:59
Subject : Re: [pgsql-hackers-win32] [HACKERS] snprintf causes regression tests to fail