From 66fbea5041fae7c0bc4fff5ad77a21169a7ba7e7 Mon Sep 17 00:00:00 2001 From: "Vadim B. Mikheev" Date: Wed, 6 Oct 1999 03:08:46 +0000 Subject: [PATCH] Don't set BootstrapProcessingMode in AddNewRelationTuple() before heap_insert() any more. No reasons to do it, and old comments said about this. --- src/backend/catalog/heap.c | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/src/backend/catalog/heap.c b/src/backend/catalog/heap.c index e5eec36219..9946a8eff0 100644 --- a/src/backend/catalog/heap.c +++ b/src/backend/catalog/heap.c @@ -7,7 +7,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/catalog/heap.c,v 1.101 1999/10/04 02:12:26 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/catalog/heap.c,v 1.102 1999/10/06 03:08:46 vadim Exp $ * * * INTERFACE ROUTINES @@ -642,7 +642,6 @@ AddNewRelationTuple(Relation pg_class_desc, Form_pg_class new_rel_reltup; HeapTuple tup; Relation idescs[Num_pg_class_indices]; - bool isBootstrap; /* ---------------- * first we munge some of the information in our @@ -689,36 +688,23 @@ AddNewRelationTuple(Relation pg_class_desc, (char *) new_rel_reltup); tup->t_data->t_oid = new_rel_oid; - /* ---------------- - * finally insert the new tuple and free it. - * - * Note: I have no idea why we do a - * SetProcessingMode(BootstrapProcessing); - * here -cim 6/14/90 - * ---------------- + /* + * finally insert the new tuple and free it. */ - isBootstrap = IsBootstrapProcessingMode() ? true : false; - - SetProcessingMode(BootstrapProcessing); - heap_insert(pg_class_desc, tup); if (temp_relname) create_temp_relation(temp_relname, tup); - if (!isBootstrap) + if (!IsBootstrapProcessingMode()) { - /* * First, open the catalog indices and insert index tuples for the * new relation. */ - CatalogOpenIndices(Num_pg_class_indices, Name_pg_class_indices, idescs); CatalogIndexInsert(idescs, Num_pg_class_indices, pg_class_desc, tup); CatalogCloseIndices(Num_pg_class_indices, idescs); - /* now restore processing mode */ - SetProcessingMode(NormalProcessing); } pfree(tup); -- 2.40.0