Skip to content

Commit 7633cad

Browse files
author
Hiroshi Inoue
committed
SearchSysCacheTupleCopy() instead of SearchSysCache()
1 parent c7eb18f commit 7633cad

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/backend/commands/creatinh.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/commands/Attic/creatinh.c,v 1.65 2000/11/08 22:09:57 tgl Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/commands/Attic/creatinh.c,v 1.66 2000/11/13 09:16:55 inoue Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -756,7 +756,7 @@ setRelhassubclassInRelation(Oid relationId, bool relhassubclass)
756756
* lock to it.
757757
*/
758758
relationRelation = heap_openr(RelationRelationName, RowExclusiveLock);
759-
tuple = SearchSysCacheTuple(RELOID,
759+
tuple = SearchSysCacheTupleCopy(RELOID,
760760
ObjectIdGetDatum(relationId),
761761
0, 0, 0)
762762
;
@@ -771,6 +771,7 @@ setRelhassubclassInRelation(Oid relationId, bool relhassubclass)
771771
);
772772
CatalogCloseIndices(Num_pg_class_indices, idescs);
773773

774+
heap_freetuple(tuple);
774775
heap_close(relationRelation, RowExclusiveLock);
775776
}
776777

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy