pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andrew Gierth <andrew@tao11.riddles.org.uk>
To: Alexander Korotkov <a.korotkov@postgrespro.ru>
Cc: pgsql-bugs@lists.postgresql.org, Teodor Sigaev <teodor@sigaev.ru>
Subject: Re: BUG #15378: SP-GIST memory context screwup?
Date: Tue, 11 Sep 2018 15:53:43 +0100
Message-ID: <8736ugqekv.fsf@news-spur.riddles.org.uk> (raw)
In-Reply-To: <CAPpHfdvbVMjB7ORQeXRxMX65u7P-TfG66bZh5U7+3j2QTAov-A@mail.gmail.com>
References: <153663176628.23136.11901365223750051490@wrigleys.postgresql.org>
	<87bm94rba5.fsf@news-spur.riddles.org.uk>
	<CAPpHfdvbVMjB7ORQeXRxMX65u7P-TfG66bZh5U7+3j2QTAov-A@mail.gmail.com>

>>>>> "Alexander" == Alexander Korotkov <a.korotkov@postgrespro.ru> writes:

 >> So this logic was added in ccd6eb49a and was wrong from the start.
 >> Testing suggests that removing the offending pfree does indeed fix
 >> the issue; any objections?

 Alexander> No objections from me. What about moving
 Alexander> MemoryContextReset(so->traversalCxt) into
 Alexander> resetSpGistScanOpaque()? For me it seems that resetting of
 Alexander> traversal memory context is part of opaque reset.

Looking at all those retail pfrees makes me itch... is there some reason
why reconstructedValue couldn't go in the traversal context too, and
then the list nodes could go there as well, and the whole thing freed
with a context reset?

-- 
Andrew (irc:RhodiumToad)




view thread (8+ messages)  latest in thread

Message-ID: <8736ugqekv.fsf@news-spur.riddles.org.uk>
Permalink:  ../8736ugqekv.fsf@news-spur.riddles.org.uk/
Also on:    postgresql.org/message-id/8736ugqekv.fsf@news-spur.riddles.org.uk

 · 

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: andrew@tao11.riddles.org.uk, a.korotkov@postgrespro.ru, teodor@sigaev.ru
  Subject: Re: BUG #15378: SP-GIST memory context screwup?
  In-Reply-To: <8736ugqekv.fsf@news-spur.riddles.org.uk>
  References: <153663176628.23136.11901365223750051490@wrigleys.postgresql.org> <87bm94rba5.fsf@news-spur.riddles.org.uk> <CAPpHfdvbVMjB7ORQeXRxMX65u7P-TfG66bZh5U7+3j2QTAov-A@mail.gmail.com> <8736ugqekv.fsf@news-spur.riddles.org.uk>

* 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