From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: Andrew Dunstan <andrew@dunslane.net>
Cc: Andres Freund <andres@anarazel.de>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: exclusion@gmail.com
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #17994: Invalidating relcache corrupts tupDesc inside ExecEvalFieldStoreDeForm()
Date: Mon, 21 Aug 2023 14:33:37 +0200
Message-ID: <20230821123337.fytudn7wtjlgtttk@alvherre.pgsql> (raw)
In-Reply-To: <0ac465e9-f6e2-4927-5aa9-a45ed6ce3801@dunslane.net>
Hello,
On 2023-Jul-12, Andrew Dunstan wrote:
> + entry = hash_search(missing_cache, &key, HASH_ENTER, &found);
> +
> + if (!found)
> + {
> + /* cache miss, so we need a non-transient copy of the datum */
> + oldctx = MemoryContextSwitchTo(TopMemoryContext);
> + entry->value =
> + datumCopy(attrmiss->am_value, false, att->attlen);
> + MemoryContextSwitchTo(oldctx);
> + }
Hmm ... when exactly do these values get freed if no longer needed? Is
the theory that leaking them is not relevant?
--
Álvaro Herrera 48°01'N 7°57'E — https://www.EnterpriseDB.com/
"Oh, great altar of passive entertainment, bestow upon me thy discordant images
at such speed as to render linear thought impossible" (Calvin a la TV)
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 using the --to and --cc options:
reply via email
To: pgsql-bugs@postgresql.org
Cc: alvherre@alvh.no-ip.org, andrew@dunslane.net, andres@anarazel.de, tgl@sss.pgh.pa.us, exclusion@gmail.com, pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #17994: Invalidating relcache corrupts tupDesc inside ExecEvalFieldStoreDeForm()
In-Reply-To: <20230821123337.fytudn7wtjlgtttk@alvherre.pgsql>
* 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