1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-10 17:42:29 +03:00

Change elog(WARN) to elog(ERROR) and elog(ABORT).

This commit is contained in:
Bruce Momjian
1998-01-05 03:35:55 +00:00
parent 0af9137f14
commit 0d9fc5afd6
188 changed files with 1436 additions and 1433 deletions

View File

@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.28 1997/11/02 15:24:09 vadim Exp $
* $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.29 1998/01/05 03:28:57 momjian Exp $
*
* NOTES
* The old interface functions have been converted to macros
@@ -93,7 +93,7 @@ ComputeDataSize(TupleDesc tupleDesc,
break;
default:
if (att[i]->attlen < sizeof(int32))
elog(WARN, "ComputeDataSize: attribute %d has len %d",
elog(ABORT, "ComputeDataSize: attribute %d has len %d",
i, att[i]->attlen);
if (att[i]->attalign == 'd')
data_length = DOUBLEALIGN(data_length) + att[i]->attlen;
@@ -194,7 +194,7 @@ DataFill(char *data,
break;
default:
if (att[i]->attlen < sizeof(int32))
elog(WARN, "DataFill: attribute %d has len %d",
elog(ABORT, "DataFill: attribute %d has len %d",
i, att[i]->attlen);
if (att[i]->attalign == 'd')
{
@@ -249,10 +249,10 @@ heap_attisnull(HeapTuple tup, int attnum)
break;
case 0:
elog(WARN, "heap_attisnull: zero attnum disallowed");
elog(ABORT, "heap_attisnull: zero attnum disallowed");
default:
elog(WARN, "heap_attisnull: undefined negative attnum");
elog(ABORT, "heap_attisnull: undefined negative attnum");
}
return (0);
@@ -290,7 +290,7 @@ heap_sysattrlen(AttrNumber attno)
return sizeof f->t_cmax;
default:
elog(WARN, "sysattrlen: System attribute number %d unknown.", attno);
elog(ABORT, "sysattrlen: System attribute number %d unknown.", attno);
return 0;
}
}
@@ -328,7 +328,7 @@ heap_sysattrbyval(AttrNumber attno)
break;
default:
byval = true;
elog(WARN, "sysattrbyval: System attribute number %d unknown.",
elog(ABORT, "sysattrbyval: System attribute number %d unknown.",
attno);
break;
}
@@ -358,7 +358,7 @@ heap_getsysattr(HeapTuple tup, Buffer b, int attnum)
case MaxCommandIdAttributeNumber:
return ((Datum) (long) tup->t_cmax);
default:
elog(WARN, "heap_getsysattr: undefined attnum %d", attnum);
elog(ABORT, "heap_getsysattr: undefined attnum %d", attnum);
}
return ((Datum) NULL);
}
@@ -538,7 +538,7 @@ fastgetattr(HeapTuple tup,
default:
if (att[j]->attlen < sizeof(int32))
{
elog(WARN,
elog(ABORT,
"fastgetattr: attribute %d has len %d",
j, att[j]->attlen);
}
@@ -598,7 +598,7 @@ fastgetattr(HeapTuple tup,
break;
default:
if (att[i]->attlen < sizeof(int32))
elog(WARN,
elog(ABORT,
"fastgetattr2: attribute %d has len %d",
i, att[i]->attlen);
if (att[i]->attalign == 'd')
@@ -657,7 +657,7 @@ fastgetattr(HeapTuple tup,
break;
default:
if (att[attnum]->attlen < sizeof(int32))
elog(WARN, "fastgetattr3: attribute %d has len %d",
elog(ABORT, "fastgetattr3: attribute %d has len %d",
attnum, att[attnum]->attlen);
if (att[attnum]->attalign == 'd')
off = DOUBLEALIGN(off);
@@ -686,7 +686,7 @@ heap_copytuple(HeapTuple tuple)
/* XXX For now, just prevent an undetectable executor related error */
if (tuple->t_len > MAXTUPLEN)
{
elog(WARN, "palloctup: cannot handle length %d tuples",
elog(ABORT, "palloctup: cannot handle length %d tuples",
tuple->t_len);
}
@@ -773,7 +773,7 @@ heap_formtuple(TupleDesc tupleDescriptor,
}
if (numberOfAttributes > MaxHeapAttributeNumber)
elog(WARN, "heap_formtuple: numberOfAttributes of %d > %d",
elog(ABORT, "heap_formtuple: numberOfAttributes of %d > %d",
numberOfAttributes, MaxHeapAttributeNumber);
if (hasnull)
@@ -883,7 +883,7 @@ heap_modifytuple(HeapTuple tuple,
}
else if (repl[attoff] != 'r')
{
elog(WARN, "heap_modifytuple: repl is \\%3d", repl[attoff]);
elog(ABORT, "heap_modifytuple: repl is \\%3d", repl[attoff]);
}
else

View File

@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/indextuple.c,v 1.20 1997/11/02 15:24:11 vadim Exp $
* $Header: /cvsroot/pgsql/src/backend/access/common/indextuple.c,v 1.21 1998/01/05 03:28:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -56,7 +56,7 @@ index_formtuple(TupleDesc tupleDescriptor,
int numberOfAttributes = tupleDescriptor->natts;
if (numberOfAttributes > MaxIndexAttributeNumber)
elog(WARN, "index_formtuple: numberOfAttributes of %d > %d",
elog(ABORT, "index_formtuple: numberOfAttributes of %d > %d",
numberOfAttributes, MaxIndexAttributeNumber);
@@ -103,7 +103,7 @@ index_formtuple(TupleDesc tupleDescriptor,
*/
if (size & 0xE000)
elog(WARN, "index_formtuple: data takes %d bytes: too big", size);
elog(ABORT, "index_formtuple: data takes %d bytes: too big", size);
infomask |= size;
@@ -314,7 +314,7 @@ fastgetiattr(IndexTuple tup,
off = (att[j]->attalign == 'd') ?
DOUBLEALIGN(off) : LONGALIGN(off);
else
elog(WARN, "fastgetiattr: attribute %d has len %d",
elog(ABORT, "fastgetiattr: attribute %d has len %d",
j, att[j]->attlen);
break;
@@ -382,7 +382,7 @@ fastgetiattr(IndexTuple tup,
DOUBLEALIGN(off) + att[i]->attlen :
LONGALIGN(off) + att[i]->attlen;
else
elog(WARN, "fastgetiattr2: attribute %d has len %d",
elog(ABORT, "fastgetiattr2: attribute %d has len %d",
i, att[i]->attlen);
break;
@@ -409,7 +409,7 @@ fastgetiattr(IndexTuple tup,
break;
default:
if (att[attnum]->attlen < sizeof(int32))
elog(WARN, "fastgetattr3: attribute %d has len %d",
elog(ABORT, "fastgetattr3: attribute %d has len %d",
attnum, att[attnum]->attlen);
if (att[attnum]->attalign == 'd')
off = DOUBLEALIGN(off);

View File

@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/printtup.c,v 1.20 1997/12/08 04:42:43 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/access/common/printtup.c,v 1.21 1998/01/05 03:29:00 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -45,7 +45,7 @@ typtoout(Oid type)
return ((Oid)
((TypeTupleForm) GETSTRUCT(typeTuple))->typoutput);
elog(WARN, "typtoout: Cache lookup of type %d failed", type);
elog(ABORT, "typtoout: Cache lookup of type %d failed", type);
return (InvalidOid);
}
@@ -62,7 +62,7 @@ gettypelem(Oid type)
return ((Oid)
((TypeTupleForm) GETSTRUCT(typeTuple))->typelem);
elog(WARN, "typtoout: Cache lookup of type %d failed", type);
elog(ABORT, "typtoout: Cache lookup of type %d failed", type);
return (InvalidOid);
}

View File

@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.29 1997/11/25 21:58:35 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.30 1998/01/05 03:29:01 momjian Exp $
*
* NOTES
* some of the executor utility code such as "ExecTypeFromTL" should be
@@ -321,7 +321,7 @@ TupleDescInitEntry(TupleDesc desc,
* RelationNameCreateHeapRelation() calls BuildDesc() which
* calls this routine and since EMP does not exist yet, the
* system cache lookup below fails. That's fine, but rather
* then doing a elog(WARN) we just leave that information
* then doing a elog(ABORT) we just leave that information
* uninitialized, return false, then fix things up later.
* -cim 6/14/90
* ----------------
@@ -508,7 +508,7 @@ BuildDescForRelation(List *schema, char *relname)
TupleDescMakeSelfReference(desc, attnum, relname);
}
else
elog(WARN, "DefineRelation: no such type %s",
elog(ABORT, "DefineRelation: no such type %s",
typename);
}