mirror of
https://github.com/postgres/postgres.git
synced 2025-06-30 21:42:05 +03:00
Checking to decide whether relations are system relations now depends
on the namespace not the name; pg_ is not a reserved prefix for table names anymore. From Fernando Nasser.
This commit is contained in:
6
src/backend/utils/cache/relcache.c
vendored
6
src/backend/utils/cache/relcache.c
vendored
@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.159 2002/03/31 06:26:31 tgl Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.160 2002/04/12 20:38:29 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -183,7 +183,7 @@ do { \
|
||||
elog(ERROR, "out of memory for relation descriptor cache"); \
|
||||
/* used to give notice if found -- now just keep quiet */ \
|
||||
nodentry->reldesc = RELATION; \
|
||||
if (RelationGetNamespace(RELATION) == PG_CATALOG_NAMESPACE) \
|
||||
if (IsSystemNamespace(RelationGetNamespace(RELATION))) \
|
||||
{ \
|
||||
char *relname = RelationGetRelationName(RELATION); \
|
||||
RelNameCacheEnt *namehentry; \
|
||||
@ -244,7 +244,7 @@ do { \
|
||||
HASH_REMOVE, NULL); \
|
||||
if (nodentry == NULL) \
|
||||
elog(WARNING, "trying to delete a reldesc that does not exist."); \
|
||||
if (RelationGetNamespace(RELATION) == PG_CATALOG_NAMESPACE) \
|
||||
if (IsSystemNamespace(RelationGetNamespace(RELATION))) \
|
||||
{ \
|
||||
char *relname = RelationGetRelationName(RELATION); \
|
||||
RelNameCacheEnt *namehentry; \
|
||||
|
Reference in New Issue
Block a user