pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Heikki Linnakangas <hlinnaka@iki.fi>
Cc: Peter Geoghegan <pg@heroku.com>
Cc: David Rowley <david.rowley@2ndquadrant.com>
Cc: Michael Paquier <michael.paquier@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Regina Obe <lr@pcorp.us>
Cc: PostgreSQL mailing lists <pgsql-bugs@postgresql.org>
Subject: Re: BUG #14344: string_agg(DISTINCT ..) crash
Date: Mon, 17 Oct 2016 09:42:13 -0400
Message-ID: <7256.1476711733@sss.pgh.pa.us> (raw)
In-Reply-To: <d99ea540-80cc-fc1b-e1b8-3d4fd205e31f@iki.fi>
References: <20160929035538.20224.39628@wrigleys.postgresql.org>
	<CAM3SWZSJyUvakbibG6cP_3gLVnVDaPKzHPjyh43Ap54Za9xDxg@mail.gmail.com>
	<CAKJS1f9V=OQb_JyZ8HmeLonJMhQFJe9PFzE77F2KTED1AqTXNw@mail.gmail.com>
	<CAM3SWZQWjMkRbH=D0Yp-i0Jaj2vmWupN-3E_f8keAh-7UQeRFw@mail.gmail.com>
	<CAKJS1f_4aw+Lfm=xUxfGQe-LQiNJc=OrfBYkg58By2Gn-aL5Zg@mail.gmail.com>
	<CAM3SWZRF5fuuBnk6jBtsjND6LY8g1xhX=3QKBwhq=bw7sG_BGw@mail.gmail.com>
	<CAM3SWZQxeF5r4=U9-ikgn86Zun+LbcRfv6gQ0SWdWPQ5XVC6BQ@mail.gmail.com>
	<22270.1475163646@sss.pgh.pa.us>
	<CAM3SWZTQcmnutjza3GdLLC-Y4WmF_FKAfAxLF4EMVK_dS3RsEQ@mail.gmail.com>
	<ce6f5ca3-1576-43dd-e02d-e23f344ee316@iki.fi>
	<CAM3SWZQaUAowLqNE9xr+5ovFaEoU_SW9GVVUYthUnhDCvgOehw@mail.gmail.com>
	<CAM3SWZQ6+C7xJKRNGxyRJLadaRBADsq4=0dOkbLmVCTHoXBV9w@mail.gmail.com>
	<CAM3SWZSAPkKmbAFUHC3e6qszfMTnsUzv137Fi2Mcyg-rfEebKQ@mail.gmail.com>
	<5b2d9da9-d2a9-ee53-aab4-1112f8dcf072@iki.fi>
	<CAM3SWZSgrrk9eBF3uQRuDm8MMoSQzv8-8Uc4Rihsy75Svh_bRw@mail.gmail.com>
	<d99ea540-80cc-fc1b-e1b8-3d4fd205e31f@ik! i.fi>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>

Heikki Linnakangas <hlinnaka@iki.fi> writes:
> On 10/13/2016 08:27 PM, Peter Geoghegan wrote:
>> The point I'm making is that we might be better off worrying about the
>> general problem, by adding a tuplestore_gettupleslot()-style "copy"
>> boolean argument at the same time, and having some callers pass
>> "false" to avoid copying (when they determine no risk of
>> use-after-free, by not keeping the contents of a slot active across
>> calls to tuplesort_gettupleslot()). You indicated that you don't
>> really want to go there for 9.6, but maybe it's worth reconsidering
>> that. For example, maybe ABI breakage is avoided by making
>> tuplesort_gettupleslot() into a shim. Or, maybe it's okay to put it in
>> the release notes of 9.6.1 -- I'm not sure how manageable that is.

> Pushed this isolated fix for now.

FWIW, I think this is an appropriate solution for 9.6, but I'd favor
changing the function's API to be like tuplestore_gettupleslot's
in HEAD.

			regards, tom lane


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



view thread (30+ messages)  latest in thread

Message-ID: <7256.1476711733@sss.pgh.pa.us>
Permalink:  ../7256.1476711733@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/7256.1476711733@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, hlinnaka@iki.fi, pg@heroku.com, david.rowley@2ndquadrant.com, michael.paquier@gmail.com, robertmhaas@gmail.com, lr@pcorp.us
  Subject: Re: BUG #14344: string_agg(DISTINCT ..) crash
  In-Reply-To: <7256.1476711733@sss.pgh.pa.us>
  References: <20160929035538.20224.39628@wrigleys.postgresql.org> <CAM3SWZSJyUvakbibG6cP_3gLVnVDaPKzHPjyh43Ap54Za9xDxg@mail.gmail.com> <CAKJS1f9V=OQb_JyZ8HmeLonJMhQFJe9PFzE77F2KTED1AqTXNw@mail.gmail.com> <CAM3SWZQWjMkRbH=D0Yp-i0Jaj2vmWupN-3E_f8keAh-7UQeRFw@mail.gmail.com> <CAKJS1f_4aw+Lfm=xUxfGQe-LQiNJc=OrfBYkg58By2Gn-aL5Zg@mail.gmail.com> <CAM3SWZRF5fuuBnk6jBtsjND6LY8g1xhX=3QKBwhq=bw7sG_BGw@mail.gmail.com> <CAM3SWZQxeF5r4=U9-ikgn86Zun+LbcRfv6gQ0SWdWPQ5XVC6BQ@mail.gmail.com> <22270.1475163646@sss.pgh.pa.us> <CAM3SWZTQcmnutjza3GdLLC-Y4WmF_FKAfAxLF4EMVK_dS3RsEQ@mail.gmail.com> <ce6f5ca3-1576-43dd-e02d-e23f344ee316@iki.fi> <CAM3SWZQaUAowLqNE9xr+5ovFaEoU_SW9GVVUYthUnhDCvgOehw@mail.gmail.com> <CAM3SWZQ6+C7xJKRNGxyRJLadaRBADsq4=0dOkbLmVCTHoXBV9w@mail.gmail.com> <CAM3SWZSAPkKmbAFUHC3e6qszfMTnsUzv137Fi2Mcyg-rfEebKQ@mail.gmail.com> <5b2d9da9-d2a9-ee53-aab4-1112f8dcf072@iki.fi> <CAM3SWZSgrrk9eBF3uQRuDm8MMoSQzv8-8Uc4Rihsy75Svh_bRw@mail.gmail.com> <7256.1476711733@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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