aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/cache
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>1998-01-05 03:35:55 +0000
committerBruce Momjian <bruce@momjian.us>1998-01-05 03:35:55 +0000
commit0d9fc5afd6eda651d2ef0a4776e08f02d32a96de (patch)
treec9f5ac32c61569ba21fc66cf28d383e3972d2199 /src/backend/utils/cache
parent0af9137f14f46a0affba6e57343a76a1e832172f (diff)
downloadpostgresql-0d9fc5afd6eda651d2ef0a4776e08f02d32a96de.tar.gz
postgresql-0d9fc5afd6eda651d2ef0a4776e08f02d32a96de.zip
Change elog(WARN) to elog(ERROR) and elog(ABORT).
Diffstat (limited to 'src/backend/utils/cache')
-rw-r--r--src/backend/utils/cache/catcache.c8
-rw-r--r--src/backend/utils/cache/fcache.c12
-rw-r--r--src/backend/utils/cache/lsyscache.c6
-rw-r--r--src/backend/utils/cache/relcache.c30
-rw-r--r--src/backend/utils/cache/syscache.c12
5 files changed, 34 insertions, 34 deletions
diff --git a/src/backend/utils/cache/catcache.c b/src/backend/utils/cache/catcache.c
index 86c15b63016..f49b58d5912 100644
--- a/src/backend/utils/cache/catcache.c
+++ b/src/backend/utils/cache/catcache.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.18 1997/11/24 05:09:09 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.19 1998/01/05 03:34:22 momjian Exp $
*
* Notes:
* XXX This needs to use exception.h to handle recovery when
@@ -568,7 +568,7 @@ ResetSystemCache()
CACHE1_elog(DEBUG, "ResetSystemCache called");
if (DisableCache)
{
- elog(WARN, "ResetSystemCache: Called while cache disabled");
+ elog(ABORT, "ResetSystemCache: Called while cache disabled");
return;
}
@@ -605,7 +605,7 @@ ResetSystemCache()
nextelt = DLGetSucc(elt);
CatCacheRemoveCTup(cache, elt);
if (cache->cc_ntup == -1)
- elog(WARN, "ResetSystemCache: cc_ntup<0 (software error)");
+ elog(ABORT, "ResetSystemCache: cc_ntup<0 (software error)");
}
}
cache->cc_ntup = 0; /* in case of WARN error above */
@@ -892,7 +892,7 @@ SearchSysCache(struct catcache * cache,
if (DisableCache)
{
- elog(WARN, "SearchSysCache: Called while cache disabled");
+ elog(ABORT, "SearchSysCache: Called while cache disabled");
return ((HeapTuple) NULL);
}
diff --git a/src/backend/utils/cache/fcache.c b/src/backend/utils/cache/fcache.c
index 7bfa62e564b..fa480813f0b 100644
--- a/src/backend/utils/cache/fcache.c
+++ b/src/backend/utils/cache/fcache.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/fcache.c,v 1.7 1997/09/08 21:48:49 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/fcache.c,v 1.8 1998/01/05 03:34:24 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -71,7 +71,7 @@ GetDynamicFuncArgType(Var *arg, ExprContext *econtext)
tup = SearchSysCacheTuple(TYPNAME, PointerGetDatum(relname),
0, 0, 0);
if (!tup)
- elog(WARN, "Lookup failed on type tuple for class %s",
+ elog(ABORT, "Lookup failed on type tuple for class %s",
relname);
return tup->t_oid;
@@ -100,14 +100,14 @@ init_fcache(Oid foid,
retval = (FunctionCachePtr) palloc(sizeof(FunctionCache));
if (!use_syscache)
- elog(WARN, "what the ????, init the fcache without the catalogs?");
+ elog(ABORT, "what the ????, init the fcache without the catalogs?");
procedureTuple = SearchSysCacheTuple(PROOID,
ObjectIdGetDatum(foid),
0, 0, 0);
if (!HeapTupleIsValid(procedureTuple))
- elog(WARN,
+ elog(ABORT,
"init_fcache: %s %d",
"Cache lookup failed for procedure", foid);
@@ -128,7 +128,7 @@ init_fcache(Oid foid,
0, 0, 0);
if (!HeapTupleIsValid(typeTuple))
- elog(WARN,
+ elog(ABORT,
"init_fcache: %s %d",
"Cache lookup failed for type",
(procedureStruct)->prorettype);
@@ -311,6 +311,6 @@ setFcache(Node *node, Oid foid, List *argList, ExprContext *econtext)
}
else
{
- elog(WARN, "init_fcache: node must be Oper or Func!");
+ elog(ABORT, "init_fcache: node must be Oper or Func!");
}
}
diff --git a/src/backend/utils/cache/lsyscache.c b/src/backend/utils/cache/lsyscache.c
index 26980c6e2e6..fa4b0e655ca 100644
--- a/src/backend/utils/cache/lsyscache.c
+++ b/src/backend/utils/cache/lsyscache.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/lsyscache.c,v 1.7 1997/11/17 16:59:23 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/lsyscache.c,v 1.8 1998/01/05 03:34:26 momjian Exp $
*
* NOTES
* Eventually, the index information should go through here, too.
@@ -148,7 +148,7 @@ get_attisset(Oid relid, char *attname)
PointerGetDatum(attname),
0, 0);
if (!HeapTupleIsValid(htup))
- elog(WARN, "get_attisset: no attribute %s in relation %d",
+ elog(ABORT, "get_attisset: no attribute %s in relation %d",
attname, relid);
if (heap_attisnull(htup, attno))
return (false);
@@ -203,7 +203,7 @@ get_opname(Oid opno)
return (pstrdup(optup.oprname.data));
else
{
- elog(WARN, "can't look up operator %d\n", opno);
+ elog(ABORT, "can't look up operator %d\n", opno);
return NULL;
}
}
diff --git a/src/backend/utils/cache/relcache.c b/src/backend/utils/cache/relcache.c
index 90c560bbcd0..672e40fc9f1 100644
--- a/src/backend/utils/cache/relcache.c
+++ b/src/backend/utils/cache/relcache.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.30 1997/11/21 18:11:26 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.31 1998/01/05 03:34:29 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -371,7 +371,7 @@ scan_pg_rel_seq(RelationBuildDescInfo buildinfo)
break;
default:
- elog(WARN, "ScanPgRelation: bad buildinfo");
+ elog(ABORT, "ScanPgRelation: bad buildinfo");
return NULL;
}
@@ -441,7 +441,7 @@ scan_pg_rel_ind(RelationBuildDescInfo buildinfo)
break;
default:
- elog(WARN, "ScanPgRelation: bad buildinfo");
+ elog(ABORT, "ScanPgRelation: bad buildinfo");
/*
* XXX I hope this is right. It seems better than returning
@@ -583,7 +583,7 @@ build_tupdesc_seq(RelationBuildDescInfo buildinfo,
}
if (need > 0)
- elog(WARN, "catalog is missing %d attribute%s for relid %d",
+ elog(ABORT, "catalog is missing %d attribute%s for relid %d",
need, (need == 1 ? "" : "s"), relation->rd_id);
/* ----------------
@@ -617,7 +617,7 @@ build_tupdesc_ind(RelationBuildDescInfo buildinfo,
atttup = (HeapTuple) AttributeNumIndexScan(attrel, relation->rd_id, i);
if (!HeapTupleIsValid(atttup))
- elog(WARN, "cannot find attribute %d of relation %.*s", i,
+ elog(ABORT, "cannot find attribute %d of relation %.*s", i,
NAMEDATALEN, &(relation->rd_rel->relname.data[0]));
attp = (AttributeTupleForm) GETSTRUCT(atttup);
@@ -1738,7 +1738,7 @@ AttrDefaultFetch(Relation relation)
if (adform->adnum != attrdef[i].adnum)
continue;
if (attrdef[i].adsrc != NULL)
- elog(WARN, "AttrDefaultFetch: second record found for attr %.*s in rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: second record found for attr %.*s in rel %.*s",
NAMEDATALEN, relation->rd_att->attrs[adform->adnum - 1]->attname.data,
NAMEDATALEN, relation->rd_rel->relname.data);
@@ -1746,7 +1746,7 @@ AttrDefaultFetch(Relation relation)
Anum_pg_attrdef_adbin,
adrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "AttrDefaultFetch: adbin IS NULL for attr %.*s in rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: adbin IS NULL for attr %.*s in rel %.*s",
NAMEDATALEN, relation->rd_att->attrs[adform->adnum - 1]->attname.data,
NAMEDATALEN, relation->rd_rel->relname.data);
attrdef[i].adbin = textout(val);
@@ -1754,7 +1754,7 @@ AttrDefaultFetch(Relation relation)
Anum_pg_attrdef_adsrc,
adrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "AttrDefaultFetch: adsrc IS NULL for attr %.*s in rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: adsrc IS NULL for attr %.*s in rel %.*s",
NAMEDATALEN, relation->rd_att->attrs[adform->adnum - 1]->attname.data,
NAMEDATALEN, relation->rd_rel->relname.data);
attrdef[i].adsrc = textout(val);
@@ -1762,14 +1762,14 @@ AttrDefaultFetch(Relation relation)
}
if (i >= ndef)
- elog(WARN, "AttrDefaultFetch: unexpected record found for attr %d in rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: unexpected record found for attr %d in rel %.*s",
adform->adnum,
NAMEDATALEN, relation->rd_rel->relname.data);
ReleaseBuffer(buffer);
}
if (found < ndef)
- elog(WARN, "AttrDefaultFetch: %d record not found for rel %.*s",
+ elog(ABORT, "AttrDefaultFetch: %d record not found for rel %.*s",
ndef - found,
NAMEDATALEN, relation->rd_rel->relname.data);
@@ -1821,28 +1821,28 @@ RelCheckFetch(Relation relation)
if (!HeapTupleIsValid(tuple))
continue;
if (found == ncheck)
- elog(WARN, "RelCheckFetch: unexpected record found for rel %.*s",
+ elog(ABORT, "RelCheckFetch: unexpected record found for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
rcname = (Name) fastgetattr(tuple,
Anum_pg_relcheck_rcname,
rcrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "RelCheckFetch: rcname IS NULL for rel %.*s",
+ elog(ABORT, "RelCheckFetch: rcname IS NULL for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
check[found].ccname = nameout(rcname);
val = (struct varlena *) fastgetattr(tuple,
Anum_pg_relcheck_rcbin,
rcrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "RelCheckFetch: rcbin IS NULL for rel %.*s",
+ elog(ABORT, "RelCheckFetch: rcbin IS NULL for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
check[found].ccbin = textout(val);
val = (struct varlena *) fastgetattr(tuple,
Anum_pg_relcheck_rcsrc,
rcrel->rd_att, &isnull);
if (isnull)
- elog(WARN, "RelCheckFetch: rcsrc IS NULL for rel %.*s",
+ elog(ABORT, "RelCheckFetch: rcsrc IS NULL for rel %.*s",
NAMEDATALEN, relation->rd_rel->relname.data);
check[found].ccsrc = textout(val);
found++;
@@ -1851,7 +1851,7 @@ RelCheckFetch(Relation relation)
}
if (found < ncheck)
- elog(WARN, "RelCheckFetch: %d record not found for rel %.*s",
+ elog(ABORT, "RelCheckFetch: %d record not found for rel %.*s",
ncheck - found,
NAMEDATALEN, relation->rd_rel->relname.data);
diff --git a/src/backend/utils/cache/syscache.c b/src/backend/utils/cache/syscache.c
index f12e17f03d8..9d17c150ce0 100644
--- a/src/backend/utils/cache/syscache.c
+++ b/src/backend/utils/cache/syscache.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/syscache.c,v 1.10 1997/10/28 15:03:06 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/syscache.c,v 1.11 1998/01/05 03:34:32 momjian Exp $
*
* NOTES
* These routines allow the parser/planner/executor to perform
@@ -371,7 +371,7 @@ InitCatalogCache()
cacheinfo[cacheId].iScanFunc);
if (!PointerIsValid((char *) SysCache[cacheId]))
{
- elog(WARN,
+ elog(ABORT,
"InitCatalogCache: Can't init cache %.16s(%d)",
cacheinfo[cacheId].name,
cacheId);
@@ -402,7 +402,7 @@ SearchSysCacheTuple(int cacheId, /* cache selection code */
if (cacheId < 0 || cacheId >= SysCacheSize)
{
- elog(WARN, "SearchSysCacheTuple: Bad cache id %d", cacheId);
+ elog(ABORT, "SearchSysCacheTuple: Bad cache id %d", cacheId);
return ((HeapTuple) NULL);
}
@@ -423,7 +423,7 @@ SearchSysCacheTuple(int cacheId, /* cache selection code */
cacheinfo[cacheId].iScanFunc);
if (!PointerIsValid(SysCache[cacheId]))
{
- elog(WARN,
+ elog(ABORT,
"InitCatalogCache: Can't init cache %.16s(%d)",
cacheinfo[cacheId].name,
cacheId);
@@ -469,7 +469,7 @@ SearchSysCacheStruct(int cacheId, /* cache selection code */
if (!PointerIsValid(returnStruct))
{
- elog(WARN, "SearchSysCacheStruct: No receiving struct");
+ elog(ABORT, "SearchSysCacheStruct: No receiving struct");
return (0);
}
tp = SearchSysCacheTuple(cacheId, key1, key2, key3, key4);
@@ -537,7 +537,7 @@ SearchSysCacheGetAttribute(int cacheId,
}
else
{
- elog(WARN,
+ elog(ABORT,
"SearchSysCacheGetAttribute: Bad attr # %d in %s(%d)",
attributeNumber, cacheName, cacheId);
return (NULL);