diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2005-04-14 20:03:27 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2005-04-14 20:03:27 +0000 |
commit | 162bd08b3f2e6783d1d75ae79f86fc444d34a28d (patch) | |
tree | 0220cd8a906557db64763a1a57dd339de313d221 /src/backend/storage/large_object/inv_api.c | |
parent | 9dc2e6deaf66f97ff9157478a517d0f48a1e5060 (diff) | |
download | postgresql-162bd08b3f2e6783d1d75ae79f86fc444d34a28d.tar.gz postgresql-162bd08b3f2e6783d1d75ae79f86fc444d34a28d.zip |
Completion of project to use fixed OIDs for all system catalogs and
indexes. Replace all heap_openr and index_openr calls by heap_open
and index_open. Remove runtime lookups of catalog OID numbers in
various places. Remove relcache's support for looking up system
catalogs by name. Bulky but mostly very boring patch ...
Diffstat (limited to 'src/backend/storage/large_object/inv_api.c')
-rw-r--r-- | src/backend/storage/large_object/inv_api.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/src/backend/storage/large_object/inv_api.c b/src/backend/storage/large_object/inv_api.c index 34129265796..299e0756d1f 100644 --- a/src/backend/storage/large_object/inv_api.c +++ b/src/backend/storage/large_object/inv_api.c @@ -9,7 +9,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/storage/large_object/inv_api.c,v 1.109 2005/01/27 23:24:09 neilc Exp $ + * $PostgreSQL: pgsql/src/backend/storage/large_object/inv_api.c,v 1.110 2005/04/14 20:03:25 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -19,7 +19,6 @@ #include "access/heapam.h" #include "access/tuptoaster.h" #include "catalog/catalog.h" -#include "catalog/catname.h" #include "catalog/indexing.h" #include "catalog/pg_largeobject.h" #include "commands/comment.h" @@ -60,9 +59,9 @@ open_lo_relation(void) /* Use RowExclusiveLock since we might either read or write */ if (lo_heap_r == NULL) - lo_heap_r = heap_openr(LargeObjectRelationName, RowExclusiveLock); + lo_heap_r = heap_open(LargeObjectRelationId, RowExclusiveLock); if (lo_index_r == NULL) - lo_index_r = index_openr(LargeObjectLOidPNIndex); + lo_index_r = index_open(LargeObjectLOidPNIndexId); } PG_CATCH(); { @@ -230,15 +229,10 @@ inv_close(LargeObjectDesc *obj_desc) int inv_drop(Oid lobjId) { - Oid classoid; - LargeObjectDrop(lobjId); - /* pg_largeobject doesn't have a hard-coded OID, so must look it up */ - classoid = get_system_catalog_relid(LargeObjectRelationName); - /* Delete any comments on the large object */ - DeleteComments(lobjId, classoid, 0); + DeleteComments(lobjId, LargeObjectRelationId, 0); /* * Advance command counter so that tuple removal will be seen by later |