pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Fix configure's snprintf test so it exposes HP-UX bug.
3+ messages / 2 participants
[nested] [flat]

* pgsql: Fix configure's snprintf test so it exposes HP-UX bug.
@ 2018-08-17 14:38 Tom Lane <tgl@sss.pgh.pa.us>
  2018-08-24 05:48 ` Re: pgsql: Fix configure's snprintf test so it exposes HP-UX bug. Andres Freund <andres@anarazel.de>
  0 siblings, 1 reply; 3+ messages in thread

From: Tom Lane @ 2018-08-17 14:38 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix configure's snprintf test so it exposes HP-UX bug.

Since commit e1d19c902, buildfarm member gharial has been failing with
symptoms indicating that snprintf sometimes returns -1 for buffer
overrun, even though it passes the added configure check.  Some
google research suggests that this happens only in limited cases,
such as when the overrun happens partway through a %d item.  Adjust
the configure check to exercise it that way.  Since I'm now feeling
more paranoid than I was before, also make the test explicitly verify
that the buffer doesn't get physically overrun.

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/9bed827b18cc4f27fb7cd7c02ad301519eca6d29

Modified Files
--------------
config/c-library.m4 | 11 ++++++++---
configure           |  9 ++++++---
2 files changed, 14 insertions(+), 6 deletions(-)



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: pgsql: Fix configure's snprintf test so it exposes HP-UX bug.
  2018-08-17 14:38 pgsql: Fix configure's snprintf test so it exposes HP-UX bug. Tom Lane <tgl@sss.pgh.pa.us>
@ 2018-08-24 05:48 ` Andres Freund <andres@anarazel.de>
  2018-08-24 13:31   ` Re: pgsql: Fix configure's snprintf test so it exposes HP-UX bug. Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 3+ messages in thread

From: Andres Freund @ 2018-08-24 05:48 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: pgsql-committers@lists.postgresql.org

On 2018-08-17 14:38:41 +0000, Tom Lane wrote:
> Fix configure's snprintf test so it exposes HP-UX bug.
> 
> Since commit e1d19c902, buildfarm member gharial has been failing with
> symptoms indicating that snprintf sometimes returns -1 for buffer
> overrun, even though it passes the added configure check.  Some
> google research suggests that this happens only in limited cases,
> such as when the overrun happens partway through a %d item.  Adjust
> the configure check to exercise it that way.  Since I'm now feeling
> more paranoid than I was before, also make the test explicitly verify
> that the buffer doesn't get physically overrun.
> 
> Branch
> ------
> master
> 
> Details
> -------
> https://git.postgresql.org/pg/commitdiff/9bed827b18cc4f27fb7cd7c02ad301519eca6d29
> 
> Modified Files
> --------------
> config/c-library.m4 | 11 ++++++++---
> configure           |  9 ++++++---
> 2 files changed, 14 insertions(+), 6 deletions(-)

Afaictl this does not seem to have done the trick, gharial is still red?

Greetings,

Andres Freund




^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: pgsql: Fix configure's snprintf test so it exposes HP-UX bug.
  2018-08-17 14:38 pgsql: Fix configure's snprintf test so it exposes HP-UX bug. Tom Lane <tgl@sss.pgh.pa.us>
  2018-08-24 05:48 ` Re: pgsql: Fix configure's snprintf test so it exposes HP-UX bug. Andres Freund <andres@anarazel.de>
@ 2018-08-24 13:31   ` Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 3+ messages in thread

From: Tom Lane @ 2018-08-24 13:31 UTC (permalink / raw)
  To: Andres Freund <andres@anarazel.de>; +Cc: pgsql-committers@lists.postgresql.org

Andres Freund <andres@anarazel.de> writes:
> On 2018-08-17 14:38:41 +0000, Tom Lane wrote:
>> Fix configure's snprintf test so it exposes HP-UX bug.

> Afaictl this does not seem to have done the trick, gharial is still red?

Yeah :-(.  If I had access to that machine, I'd attempt to fix it.
I've not been able to get the owner's attention though.

However, it's probably moot in view of the fact that I'm now proposing
to replace snprintf unconditionally, so that this configure test is
going to go away again anyhow.

			regards, tom lane




^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2018-08-24 13:31 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2018-08-17 14:38 pgsql: Fix configure's snprintf test so it exposes HP-UX bug. Tom Lane <tgl@sss.pgh.pa.us>
2018-08-24 05:48 ` Andres Freund <andres@anarazel.de>
2018-08-24 13:31   ` Tom Lane <tgl@sss.pgh.pa.us>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox