From 06e10abc0bb4297a0754313b4f158bdd5622ca24 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Fri, 16 Jun 2006 18:42:24 +0000 Subject: Fix problems with cached tuple descriptors disappearing while still in use by creating a reference-count mechanism, similar to what we did a long time ago for catcache entries. The back branches have an ugly solution involving lots of extra copies, but this way is more efficient. Reference counting is only applied to tupdescs that are actually in caches --- there seems no need to use it for tupdescs that are generated in the executor, since they'll go away during plan shutdown by virtue of being in the per-query memory context. Neil Conway and Tom Lane --- src/backend/executor/nodeTidscan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/backend/executor/nodeTidscan.c') diff --git a/src/backend/executor/nodeTidscan.c b/src/backend/executor/nodeTidscan.c index 75862f08ac4..78fd702e70c 100644 --- a/src/backend/executor/nodeTidscan.c +++ b/src/backend/executor/nodeTidscan.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/executor/nodeTidscan.c,v 1.48 2006/03/05 15:58:26 momjian Exp $ + * $PostgreSQL: pgsql/src/backend/executor/nodeTidscan.c,v 1.49 2006/06/16 18:42:22 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -524,7 +524,7 @@ ExecInitTidScan(TidScan *node, EState *estate, int eflags) /* * get the scan type from the relation descriptor. */ - ExecAssignScanType(&tidstate->ss, RelationGetDescr(currentRelation), false); + ExecAssignScanType(&tidstate->ss, RelationGetDescr(currentRelation)); /* * Initialize result tuple type and projection info. -- cgit v1.2.3