mirror of
https://github.com/postgres/postgres.git
synced 2025-09-02 04:21:28 +03:00
Change elog(WARN) to elog(ERROR) and elog(ABORT).
This commit is contained in:
@@ -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
|
||||
|
@@ -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);
|
||||
|
@@ -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);
|
||||
}
|
||||
|
||||
|
@@ -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);
|
||||
}
|
||||
|
||||
|
@@ -130,7 +130,7 @@ gistbuild(Relation heap,
|
||||
*/
|
||||
|
||||
if (oldPred == NULL && (nb = RelationGetNumberOfBlocks(index)) != 0)
|
||||
elog(WARN, "%.16s already contains data", &(index->rd_rel->relname.data[0]));
|
||||
elog(ABORT, "%.16s already contains data", &(index->rd_rel->relname.data[0]));
|
||||
|
||||
/* initialize the root page (if this is a new index) */
|
||||
if (oldPred == NULL)
|
||||
@@ -1182,7 +1182,7 @@ initGISTstate(GISTSTATE *giststate, Relation index)
|
||||
0, 0, 0);
|
||||
itupform = (IndexTupleForm) GETSTRUCT(htup);
|
||||
if (!HeapTupleIsValid(htup))
|
||||
elog(WARN, "initGISTstate: index %d not found", index->rd_id);
|
||||
elog(ABORT, "initGISTstate: index %d not found", index->rd_id);
|
||||
giststate->haskeytype = itupform->indhaskeytype;
|
||||
if (giststate->haskeytype)
|
||||
{
|
||||
@@ -1193,7 +1193,7 @@ initGISTstate(GISTSTATE *giststate, Relation index)
|
||||
0, 0);
|
||||
if (!HeapTupleIsValid(htup))
|
||||
{
|
||||
elog(WARN, "initGISTstate: no attribute tuple %d %d",
|
||||
elog(ABORT, "initGISTstate: no attribute tuple %d %d",
|
||||
itupform->indexrelid, FirstOffsetNumber);
|
||||
return;
|
||||
}
|
||||
|
@@ -83,7 +83,7 @@ gistrescan(IndexScanDesc s, bool fromEnd, ScanKey key)
|
||||
|
||||
if (!IndexScanIsValid(s))
|
||||
{
|
||||
elog(WARN, "gistrescan: invalid scan.");
|
||||
elog(ABORT, "gistrescan: invalid scan.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -281,7 +281,7 @@ gistdropscan(IndexScanDesc s)
|
||||
}
|
||||
|
||||
if (l == (GISTScanList) NULL)
|
||||
elog(WARN, "GiST scan list corrupted -- cannot find 0x%lx", s);
|
||||
elog(ABORT, "GiST scan list corrupted -- cannot find 0x%lx", s);
|
||||
|
||||
if (prev == (GISTScanList) NULL)
|
||||
GISTScans = l->gsl_next;
|
||||
@@ -397,7 +397,7 @@ adjustiptr(IndexScanDesc s,
|
||||
break;
|
||||
|
||||
default:
|
||||
elog(WARN, "Bad operation in GiST scan adjust: %d", op);
|
||||
elog(ABORT, "Bad operation in GiST scan adjust: %d", op);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashinsert.c,v 1.10 1997/09/08 02:20:16 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashinsert.c,v 1.11 1998/01/05 03:29:15 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -49,7 +49,7 @@ _hash_doinsert(Relation rel, HashItem hitem)
|
||||
/* we need a scan key to do our search, so build one */
|
||||
itup = &(hitem->hash_itup);
|
||||
if ((natts = rel->rd_rel->relnatts) != 1)
|
||||
elog(WARN, "Hash indices valid for only one index key.");
|
||||
elog(ABORT, "Hash indices valid for only one index key.");
|
||||
itup_scankey = _hash_mkscankey(rel, itup, metap);
|
||||
|
||||
/*
|
||||
@@ -167,7 +167,7 @@ _hash_insertonpg(Relation rel,
|
||||
if (PageGetFreeSpace(page) < itemsz)
|
||||
{
|
||||
/* it doesn't fit on an empty page -- give up */
|
||||
elog(WARN, "hash item too large");
|
||||
elog(ABORT, "hash item too large");
|
||||
}
|
||||
}
|
||||
_hash_checkpage(page, LH_OVERFLOW_PAGE);
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashovfl.c,v 1.13 1997/09/18 20:19:43 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashovfl.c,v 1.14 1998/01/05 03:29:20 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Overflow pages look like ordinary relation pages.
|
||||
@@ -65,7 +65,7 @@ _hash_addovflpage(Relation rel, Buffer *metabufp, Buffer buf)
|
||||
oaddr = _hash_getovfladdr(rel, metabufp);
|
||||
if (oaddr == InvalidOvflAddress)
|
||||
{
|
||||
elog(WARN, "_hash_addovflpage: problem with _hash_getovfladdr.");
|
||||
elog(ABORT, "_hash_addovflpage: problem with _hash_getovfladdr.");
|
||||
}
|
||||
ovflblkno = OADDR_TO_BLKNO(OADDR_OF(SPLITNUM(oaddr), OPAGENUM(oaddr)));
|
||||
Assert(BlockNumberIsValid(ovflblkno));
|
||||
@@ -172,7 +172,7 @@ _hash_getovfladdr(Relation rel, Buffer *metabufp)
|
||||
{
|
||||
if (++splitnum >= NCACHED)
|
||||
{
|
||||
elog(WARN, OVMSG);
|
||||
elog(ABORT, OVMSG);
|
||||
}
|
||||
metap->OVFL_POINT = splitnum;
|
||||
metap->SPARES[splitnum] = metap->SPARES[splitnum - 1];
|
||||
@@ -190,7 +190,7 @@ _hash_getovfladdr(Relation rel, Buffer *metabufp)
|
||||
free_page++;
|
||||
if (free_page >= NCACHED)
|
||||
{
|
||||
elog(WARN, OVMSG);
|
||||
elog(ABORT, OVMSG);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -206,7 +206,7 @@ _hash_getovfladdr(Relation rel, Buffer *metabufp)
|
||||
if (_hash_initbitmap(rel, metap, OADDR_OF(splitnum, offset),
|
||||
1, free_page))
|
||||
{
|
||||
elog(WARN, "overflow_page: problem with _hash_initbitmap.");
|
||||
elog(ABORT, "overflow_page: problem with _hash_initbitmap.");
|
||||
}
|
||||
metap->SPARES[splitnum]++;
|
||||
offset++;
|
||||
@@ -214,7 +214,7 @@ _hash_getovfladdr(Relation rel, Buffer *metabufp)
|
||||
{
|
||||
if (++splitnum >= NCACHED)
|
||||
{
|
||||
elog(WARN, OVMSG);
|
||||
elog(ABORT, OVMSG);
|
||||
}
|
||||
metap->OVFL_POINT = splitnum;
|
||||
metap->SPARES[splitnum] = metap->SPARES[splitnum - 1];
|
||||
@@ -262,7 +262,7 @@ found:
|
||||
offset = (i ? bit - metap->SPARES[i - 1] : bit);
|
||||
if (offset >= SPLITMASK)
|
||||
{
|
||||
elog(WARN, OVMSG);
|
||||
elog(ABORT, OVMSG);
|
||||
}
|
||||
|
||||
/* initialize this page */
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashpage.c,v 1.13 1997/09/18 20:19:46 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashpage.c,v 1.14 1998/01/05 03:29:22 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Postgres hash pages look like ordinary relation pages. The opaque
|
||||
@@ -85,7 +85,7 @@ _hash_metapinit(Relation rel)
|
||||
|
||||
if ((nblocks = RelationGetNumberOfBlocks(rel)) != 0)
|
||||
{
|
||||
elog(WARN, "Cannot initialize non-empty hash table %s",
|
||||
elog(ABORT, "Cannot initialize non-empty hash table %s",
|
||||
RelationGetRelationName(rel));
|
||||
}
|
||||
|
||||
@@ -146,7 +146,7 @@ _hash_metapinit(Relation rel)
|
||||
* created the first two buckets above.
|
||||
*/
|
||||
if (_hash_initbitmap(rel, metap, OADDR_OF(lg2nelem, 1), lg2nelem + 1, 0))
|
||||
elog(WARN, "Problem with _hash_initbitmap.");
|
||||
elog(ABORT, "Problem with _hash_initbitmap.");
|
||||
|
||||
/* all done */
|
||||
_hash_wrtnorelbuf(rel, metabuf);
|
||||
@@ -192,7 +192,7 @@ _hash_getbuf(Relation rel, BlockNumber blkno, int access)
|
||||
|
||||
if (blkno == P_NEW)
|
||||
{
|
||||
elog(WARN, "_hash_getbuf: internal error: hash AM does not use P_NEW");
|
||||
elog(ABORT, "_hash_getbuf: internal error: hash AM does not use P_NEW");
|
||||
}
|
||||
switch (access)
|
||||
{
|
||||
@@ -201,7 +201,7 @@ _hash_getbuf(Relation rel, BlockNumber blkno, int access)
|
||||
_hash_setpagelock(rel, blkno, access);
|
||||
break;
|
||||
default:
|
||||
elog(WARN, "_hash_getbuf: invalid access (%d) on new blk: %s",
|
||||
elog(ABORT, "_hash_getbuf: invalid access (%d) on new blk: %s",
|
||||
access, RelationGetRelationName(rel));
|
||||
break;
|
||||
}
|
||||
@@ -228,7 +228,7 @@ _hash_relbuf(Relation rel, Buffer buf, int access)
|
||||
_hash_unsetpagelock(rel, blkno, access);
|
||||
break;
|
||||
default:
|
||||
elog(WARN, "_hash_relbuf: invalid access (%d) on blk %x: %s",
|
||||
elog(ABORT, "_hash_relbuf: invalid access (%d) on blk %x: %s",
|
||||
access, blkno, RelationGetRelationName(rel));
|
||||
}
|
||||
|
||||
@@ -287,7 +287,7 @@ _hash_chgbufaccess(Relation rel,
|
||||
_hash_relbuf(rel, *bufp, from_access);
|
||||
break;
|
||||
default:
|
||||
elog(WARN, "_hash_chgbufaccess: invalid access (%d) on blk %x: %s",
|
||||
elog(ABORT, "_hash_chgbufaccess: invalid access (%d) on blk %x: %s",
|
||||
from_access, blkno, RelationGetRelationName(rel));
|
||||
break;
|
||||
}
|
||||
@@ -335,7 +335,7 @@ _hash_setpagelock(Relation rel,
|
||||
RelationSetSingleRLockPage(rel, &iptr);
|
||||
break;
|
||||
default:
|
||||
elog(WARN, "_hash_setpagelock: invalid access (%d) on blk %x: %s",
|
||||
elog(ABORT, "_hash_setpagelock: invalid access (%d) on blk %x: %s",
|
||||
access, blkno, RelationGetRelationName(rel));
|
||||
break;
|
||||
}
|
||||
@@ -362,7 +362,7 @@ _hash_unsetpagelock(Relation rel,
|
||||
RelationUnsetSingleRLockPage(rel, &iptr);
|
||||
break;
|
||||
default:
|
||||
elog(WARN, "_hash_unsetpagelock: invalid access (%d) on blk %x: %s",
|
||||
elog(ABORT, "_hash_unsetpagelock: invalid access (%d) on blk %x: %s",
|
||||
access, blkno, RelationGetRelationName(rel));
|
||||
break;
|
||||
}
|
||||
@@ -546,7 +546,7 @@ _hash_splitpage(Relation rel,
|
||||
_hash_checkpage(opage, LH_OVERFLOW_PAGE);
|
||||
if (PageIsEmpty(opage))
|
||||
{
|
||||
elog(WARN, "_hash_splitpage: empty overflow page %d", oblkno);
|
||||
elog(ABORT, "_hash_splitpage: empty overflow page %d", oblkno);
|
||||
}
|
||||
oopaque = (HashPageOpaque) PageGetSpecialPointer(opage);
|
||||
}
|
||||
@@ -588,7 +588,7 @@ _hash_splitpage(Relation rel,
|
||||
/* we're guaranteed that an ovfl page has at least 1 tuple */
|
||||
if (PageIsEmpty(opage))
|
||||
{
|
||||
elog(WARN, "_hash_splitpage: empty ovfl page %d!",
|
||||
elog(ABORT, "_hash_splitpage: empty ovfl page %d!",
|
||||
oblkno);
|
||||
}
|
||||
ooffnum = FirstOffsetNumber;
|
||||
@@ -685,7 +685,7 @@ _hash_splitpage(Relation rel,
|
||||
oopaque = (HashPageOpaque) PageGetSpecialPointer(opage);
|
||||
if (PageIsEmpty(opage))
|
||||
{
|
||||
elog(WARN, "_hash_splitpage: empty overflow page %d",
|
||||
elog(ABORT, "_hash_splitpage: empty overflow page %d",
|
||||
oblkno);
|
||||
}
|
||||
ooffnum = FirstOffsetNumber;
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashscan.c,v 1.11 1997/09/08 21:40:48 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashscan.c,v 1.12 1998/01/05 03:29:24 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Because we can be doing an index scan on a relation while we
|
||||
@@ -76,7 +76,7 @@ _hash_dropscan(IndexScanDesc scan)
|
||||
}
|
||||
|
||||
if (chk == (HashScanList) NULL)
|
||||
elog(WARN, "hash scan list trashed; can't find 0x%lx", scan);
|
||||
elog(ABORT, "hash scan list trashed; can't find 0x%lx", scan);
|
||||
|
||||
if (last == (HashScanList) NULL)
|
||||
HashScans = chk->hashsl_next;
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashutil.c,v 1.11 1997/09/08 02:20:25 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashutil.c,v 1.12 1998/01/05 03:29:26 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -79,7 +79,7 @@ _hash_formitem(IndexTuple itup)
|
||||
|
||||
/* disallow nulls in hash keys */
|
||||
if (itup->t_info & INDEX_NULL_MASK)
|
||||
elog(WARN, "hash indices cannot include null keys");
|
||||
elog(ABORT, "hash indices cannot include null keys");
|
||||
|
||||
/* make a copy of the index tuple with room for the sequence number */
|
||||
tuplen = IndexTupleSize(itup);
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/heap/heapam.c,v 1.23 1997/11/21 18:03:55 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/heap/heapam.c,v 1.24 1998/01/05 03:29:29 momjian Exp $
|
||||
*
|
||||
*
|
||||
* INTERFACE ROUTINES
|
||||
@@ -295,7 +295,7 @@ heapgettup(Relation relation,
|
||||
|
||||
#ifndef NO_BUFFERISVALID
|
||||
if (!BufferIsValid(*b))
|
||||
elog(WARN, "heapgettup: failed ReadBuffer");
|
||||
elog(ABORT, "heapgettup: failed ReadBuffer");
|
||||
#endif
|
||||
|
||||
dp = (Page) BufferGetPage(*b);
|
||||
@@ -334,7 +334,7 @@ heapgettup(Relation relation,
|
||||
#ifndef NO_BUFFERISVALID
|
||||
if (!BufferIsValid(*b))
|
||||
{
|
||||
elog(WARN, "heapgettup: failed ReadBuffer");
|
||||
elog(ABORT, "heapgettup: failed ReadBuffer");
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -381,7 +381,7 @@ heapgettup(Relation relation,
|
||||
#ifndef NO_BUFFERISVALID
|
||||
if (!BufferIsValid(*b))
|
||||
{
|
||||
elog(WARN, "heapgettup: failed ReadBuffer");
|
||||
elog(ABORT, "heapgettup: failed ReadBuffer");
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -477,7 +477,7 @@ heapgettup(Relation relation,
|
||||
#ifndef NO_BUFFERISVALID
|
||||
if (!BufferIsValid(*b))
|
||||
{
|
||||
elog(WARN, "heapgettup: failed ReadBuffer");
|
||||
elog(ABORT, "heapgettup: failed ReadBuffer");
|
||||
}
|
||||
#endif
|
||||
dp = (Page) BufferGetPage(*b);
|
||||
@@ -545,7 +545,7 @@ heap_open(Oid relationId)
|
||||
|
||||
if (RelationIsValid(r) && r->rd_rel->relkind == RELKIND_INDEX)
|
||||
{
|
||||
elog(WARN, "%s is an index relation", r->rd_rel->relname.data);
|
||||
elog(ABORT, "%s is an index relation", r->rd_rel->relname.data);
|
||||
}
|
||||
|
||||
return (r);
|
||||
@@ -574,7 +574,7 @@ heap_openr(char *relationName)
|
||||
|
||||
if (RelationIsValid(r) && r->rd_rel->relkind == RELKIND_INDEX)
|
||||
{
|
||||
elog(WARN, "%s is an index relation", r->rd_rel->relname.data);
|
||||
elog(ABORT, "%s is an index relation", r->rd_rel->relname.data);
|
||||
}
|
||||
|
||||
return (r);
|
||||
@@ -626,7 +626,7 @@ heap_beginscan(Relation relation,
|
||||
* ----------------
|
||||
*/
|
||||
if (RelationIsValid(relation) == false)
|
||||
elog(WARN, "heap_beginscan: !RelationIsValid(relation)");
|
||||
elog(ABORT, "heap_beginscan: !RelationIsValid(relation)");
|
||||
|
||||
/* ----------------
|
||||
* set relation level read lock
|
||||
@@ -808,7 +808,7 @@ heap_getnext(HeapScanDesc scandesc,
|
||||
* ----------------
|
||||
*/
|
||||
if (sdesc == NULL)
|
||||
elog(WARN, "heap_getnext: NULL relscan");
|
||||
elog(ABORT, "heap_getnext: NULL relscan");
|
||||
|
||||
/* ----------------
|
||||
* initialize return buffer to InvalidBuffer
|
||||
@@ -1051,7 +1051,7 @@ heap_fetch(Relation relation,
|
||||
#ifndef NO_BUFFERISVALID
|
||||
if (!BufferIsValid(buffer))
|
||||
{
|
||||
elog(WARN, "heap_fetch: %s relation: ReadBuffer(%lx) failed",
|
||||
elog(ABORT, "heap_fetch: %s relation: ReadBuffer(%lx) failed",
|
||||
&relation->rd_rel->relname, (long) tid);
|
||||
}
|
||||
#endif
|
||||
@@ -1216,7 +1216,7 @@ heap_delete(Relation relation, ItemPointer tid)
|
||||
#ifndef NO_BUFFERISVALID
|
||||
if (!BufferIsValid(b))
|
||||
{ /* XXX L_SH better ??? */
|
||||
elog(WARN, "heap_delete: failed ReadBuffer");
|
||||
elog(ABORT, "heap_delete: failed ReadBuffer");
|
||||
}
|
||||
#endif /* NO_BUFFERISVALID */
|
||||
|
||||
@@ -1249,7 +1249,7 @@ heap_delete(Relation relation, ItemPointer tid)
|
||||
/* XXX call something else */
|
||||
ReleaseBuffer(b);
|
||||
|
||||
elog(WARN, "heap_delete: (am)invalid tid");
|
||||
elog(ABORT, "heap_delete: (am)invalid tid");
|
||||
}
|
||||
|
||||
/* ----------------
|
||||
@@ -1329,7 +1329,7 @@ heap_replace(Relation relation, ItemPointer otid, HeapTuple tup)
|
||||
if (!BufferIsValid(buffer))
|
||||
{
|
||||
/* XXX L_SH better ??? */
|
||||
elog(WARN, "amreplace: failed ReadBuffer");
|
||||
elog(ABORT, "amreplace: failed ReadBuffer");
|
||||
}
|
||||
#endif /* NO_BUFFERISVALID */
|
||||
|
||||
@@ -1385,7 +1385,7 @@ heap_replace(Relation relation, ItemPointer otid, HeapTuple tup)
|
||||
if (!tuple)
|
||||
{
|
||||
ReleaseBuffer(buffer);
|
||||
elog(WARN, "heap_replace: (am)invalid otid");
|
||||
elog(ABORT, "heap_replace: (am)invalid otid");
|
||||
}
|
||||
|
||||
/* XXX order problems if not atomic assignment ??? */
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Id: hio.c,v 1.11 1997/09/08 02:20:30 momjian Exp $
|
||||
* $Id: hio.c,v 1.12 1998/01/05 03:29:30 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -60,7 +60,7 @@ RelationPutHeapTuple(Relation relation,
|
||||
#ifndef NO_BUFFERISVALID
|
||||
if (!BufferIsValid(buffer))
|
||||
{
|
||||
elog(WARN, "RelationPutHeapTuple: no buffer for %ld in %s",
|
||||
elog(ABORT, "RelationPutHeapTuple: no buffer for %ld in %s",
|
||||
blockIndex, &relation->rd_rel->relname);
|
||||
}
|
||||
#endif
|
||||
@@ -157,7 +157,7 @@ RelationPutHeapTupleAtEnd(Relation relation, HeapTuple tuple)
|
||||
PageInit(pageHeader, BufferGetPageSize(buffer), 0);
|
||||
|
||||
if (len > PageGetFreeSpace(pageHeader))
|
||||
elog(WARN, "Tuple is too big: size %d", len);
|
||||
elog(ABORT, "Tuple is too big: size %d", len);
|
||||
}
|
||||
|
||||
offnum = PageAddItem((Page) pageHeader, (Item) tuple,
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/index/genam.c,v 1.9 1997/09/08 02:20:33 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/index/genam.c,v 1.10 1998/01/05 03:29:32 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* many of the old access method routines have been turned into
|
||||
@@ -101,7 +101,7 @@ RelationGetIndexScan(Relation relation,
|
||||
IndexScanDesc scan;
|
||||
|
||||
if (!RelationIsValid(relation))
|
||||
elog(WARN, "RelationGetIndexScan: relation invalid");
|
||||
elog(ABORT, "RelationGetIndexScan: relation invalid");
|
||||
|
||||
scan = (IndexScanDesc) palloc(sizeof(IndexScanDescData));
|
||||
|
||||
@@ -150,7 +150,7 @@ IndexScanRestart(IndexScanDesc scan,
|
||||
ScanKey key)
|
||||
{
|
||||
if (!IndexScanIsValid(scan))
|
||||
elog(WARN, "IndexScanRestart: invalid scan");
|
||||
elog(ABORT, "IndexScanRestart: invalid scan");
|
||||
|
||||
ItemPointerSetInvalid(&scan->previousItemData);
|
||||
ItemPointerSetInvalid(&scan->currentItemData);
|
||||
@@ -191,7 +191,7 @@ void
|
||||
IndexScanEnd(IndexScanDesc scan)
|
||||
{
|
||||
if (!IndexScanIsValid(scan))
|
||||
elog(WARN, "IndexScanEnd: invalid scan");
|
||||
elog(ABORT, "IndexScanEnd: invalid scan");
|
||||
|
||||
pfree(scan);
|
||||
}
|
||||
@@ -274,7 +274,7 @@ void
|
||||
IndexScanRestorePosition(IndexScanDesc scan)
|
||||
{
|
||||
if (scan->flags & ScanUnmarked)
|
||||
elog(WARN, "IndexScanRestorePosition: no mark to restore");
|
||||
elog(ABORT, "IndexScanRestorePosition: no mark to restore");
|
||||
|
||||
scan->previousItemData = scan->previousMarkData;
|
||||
scan->currentItemData = scan->currentMarkData;
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/index/indexam.c,v 1.17 1997/09/12 04:07:15 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/index/indexam.c,v 1.18 1998/01/05 03:29:34 momjian Exp $
|
||||
*
|
||||
* INTERFACE ROUTINES
|
||||
* index_open - open an index relation by relationId
|
||||
@@ -103,13 +103,13 @@ Assert(RelationIsValid(relation)); \
|
||||
#define GET_REL_PROCEDURE(x,y) \
|
||||
procedure = relation->rd_am->y; \
|
||||
if (! RegProcedureIsValid(procedure)) \
|
||||
elog(WARN, "index_%s: invalid %s regproc", \
|
||||
elog(ABORT, "index_%s: invalid %s regproc", \
|
||||
CppAsString(x), CppAsString(y))
|
||||
|
||||
#define GET_SCAN_PROCEDURE(x,y) \
|
||||
procedure = scan->relation->rd_am->y; \
|
||||
if (! RegProcedureIsValid(procedure)) \
|
||||
elog(WARN, "index_%s: invalid %s regproc", \
|
||||
elog(ABORT, "index_%s: invalid %s regproc", \
|
||||
CppAsString(x), CppAsString(y))
|
||||
|
||||
|
||||
|
@@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/index/Attic/istrat.c,v 1.13 1997/11/20 23:20:07 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/index/Attic/istrat.c,v 1.14 1998/01/05 03:29:38 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -349,7 +349,7 @@ RelationGetStrategy(Relation relation,
|
||||
{
|
||||
if (!StrategyNumberIsValid(strategy))
|
||||
{
|
||||
elog(WARN, "RelationGetStrategy: corrupted evaluation");
|
||||
elog(ABORT, "RelationGetStrategy: corrupted evaluation");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -481,7 +481,7 @@ RelationInvokeStrategy(Relation relation,
|
||||
}
|
||||
}
|
||||
|
||||
elog(WARN, "RelationInvokeStrategy: cannot evaluate strategy %d",
|
||||
elog(ABORT, "RelationInvokeStrategy: cannot evaluate strategy %d",
|
||||
strategy);
|
||||
|
||||
/* not reached, just to make compiler happy */
|
||||
@@ -514,7 +514,7 @@ OperatorRelationFillScanKeyEntry(Relation operatorRelation,
|
||||
tuple = heap_getnext(scan, false, (Buffer *) NULL);
|
||||
if (!HeapTupleIsValid(tuple))
|
||||
{
|
||||
elog(WARN, "OperatorObjectIdFillScanKeyEntry: unknown operator %lu",
|
||||
elog(ABORT, "OperatorObjectIdFillScanKeyEntry: unknown operator %lu",
|
||||
(uint32) operatorObjectId);
|
||||
}
|
||||
|
||||
@@ -525,7 +525,7 @@ OperatorRelationFillScanKeyEntry(Relation operatorRelation,
|
||||
|
||||
if (!RegProcedureIsValid(entry->sk_procedure))
|
||||
{
|
||||
elog(WARN,
|
||||
elog(ABORT,
|
||||
"OperatorObjectIdFillScanKeyEntry: no procedure for operator %lu",
|
||||
(uint32) operatorObjectId);
|
||||
}
|
||||
@@ -567,7 +567,7 @@ IndexSupportInitialize(IndexStrategy indexStrategy,
|
||||
scan = heap_beginscan(relation, false, false, 1, entry);
|
||||
tuple = heap_getnext(scan, 0, (Buffer *) NULL);
|
||||
if (!HeapTupleIsValid(tuple))
|
||||
elog(WARN, "IndexSupportInitialize: corrupted catalogs");
|
||||
elog(ABORT, "IndexSupportInitialize: corrupted catalogs");
|
||||
|
||||
/*
|
||||
* XXX note that the following assumes the INDEX tuple is well formed
|
||||
@@ -583,7 +583,7 @@ IndexSupportInitialize(IndexStrategy indexStrategy,
|
||||
{
|
||||
if (attributeIndex == 0)
|
||||
{
|
||||
elog(WARN, "IndexSupportInitialize: no pg_index tuple");
|
||||
elog(ABORT, "IndexSupportInitialize: no pg_index tuple");
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.22 1997/12/09 01:40:30 thomas Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.23 1998/01/05 03:29:45 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -123,7 +123,7 @@ _bt_doinsert(Relation rel, BTItem btitem, bool index_is_unique, Relation heapRel
|
||||
htup = heap_fetch(heapRel, true, &(itup->t_tid), NULL);
|
||||
if (htup != (HeapTuple) NULL)
|
||||
{ /* it is a duplicate */
|
||||
elog(WARN, "Cannot insert a duplicate key into a unique index");
|
||||
elog(ABORT, "Cannot insert a duplicate key into a unique index");
|
||||
}
|
||||
/* get next offnum */
|
||||
if (offset < maxoff)
|
||||
@@ -1442,7 +1442,7 @@ _bt_updateitem(Relation rel,
|
||||
* if(IndexTupleDSize(newItem->bti_itup) >
|
||||
* IndexTupleDSize(item->bti_itup)) { elog(NOTICE, "trying to
|
||||
* overwrite a smaller value with a bigger one in _bt_updateitem");
|
||||
* elog(WARN, "this is not good."); }
|
||||
* elog(ABORT, "this is not good."); }
|
||||
*/
|
||||
|
||||
oldIndexTuple = &(item->bti_itup);
|
||||
|
@@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtpage.c,v 1.13 1997/09/18 20:19:49 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtpage.c,v 1.14 1998/01/05 03:29:50 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Postgres btree pages look like ordinary relation pages. The opaque
|
||||
@@ -97,7 +97,7 @@ _bt_metapinit(Relation rel)
|
||||
|
||||
if ((nblocks = RelationGetNumberOfBlocks(rel)) != 0)
|
||||
{
|
||||
elog(WARN, "Cannot initialize non-empty btree %s",
|
||||
elog(ABORT, "Cannot initialize non-empty btree %s",
|
||||
RelationGetRelationName(rel));
|
||||
}
|
||||
|
||||
@@ -146,20 +146,20 @@ _bt_checkmeta(Relation rel)
|
||||
op = (BTPageOpaque) PageGetSpecialPointer(metap);
|
||||
if (!(op->btpo_flags & BTP_META))
|
||||
{
|
||||
elog(WARN, "Invalid metapage for index %s",
|
||||
elog(ABORT, "Invalid metapage for index %s",
|
||||
RelationGetRelationName(rel));
|
||||
}
|
||||
metad = BTPageGetMeta(metap);
|
||||
|
||||
if (metad->btm_magic != BTREE_MAGIC)
|
||||
{
|
||||
elog(WARN, "Index %s is not a btree",
|
||||
elog(ABORT, "Index %s is not a btree",
|
||||
RelationGetRelationName(rel));
|
||||
}
|
||||
|
||||
if (metad->btm_version != BTREE_VERSION)
|
||||
{
|
||||
elog(WARN, "Version mismatch on %s: version %d file, version %d code",
|
||||
elog(ABORT, "Version mismatch on %s: version %d file, version %d code",
|
||||
RelationGetRelationName(rel),
|
||||
metad->btm_version, BTREE_VERSION);
|
||||
}
|
||||
@@ -204,13 +204,13 @@ _bt_getroot(Relation rel, int access)
|
||||
|
||||
if (metad->btm_magic != BTREE_MAGIC)
|
||||
{
|
||||
elog(WARN, "Index %s is not a btree",
|
||||
elog(ABORT, "Index %s is not a btree",
|
||||
RelationGetRelationName(rel));
|
||||
}
|
||||
|
||||
if (metad->btm_version != BTREE_VERSION)
|
||||
{
|
||||
elog(WARN, "Version mismatch on %s: version %d file, version %d code",
|
||||
elog(ABORT, "Version mismatch on %s: version %d file, version %d code",
|
||||
RelationGetRelationName(rel),
|
||||
metad->btm_version, BTREE_VERSION);
|
||||
}
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/Attic/nbtscan.c,v 1.10 1997/09/08 20:54:24 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/Attic/nbtscan.c,v 1.11 1998/01/05 03:29:52 momjian Exp $
|
||||
*
|
||||
*
|
||||
* NOTES
|
||||
@@ -77,7 +77,7 @@ _bt_dropscan(IndexScanDesc scan)
|
||||
}
|
||||
|
||||
if (chk == (BTScanList) NULL)
|
||||
elog(WARN, "btree scan list trashed; can't find 0x%lx", scan);
|
||||
elog(ABORT, "btree scan list trashed; can't find 0x%lx", scan);
|
||||
|
||||
if (last == (BTScanList) NULL)
|
||||
BTScans = chk->btsl_next;
|
||||
@@ -154,7 +154,7 @@ _bt_scandel(IndexScanDesc scan, int op, BlockNumber blkno, OffsetNumber offno)
|
||||
_bt_step(scan, &buf, BackwardScanDirection);
|
||||
break;
|
||||
default:
|
||||
elog(WARN, "_bt_scandel: bad operation '%d'", op);
|
||||
elog(ABORT, "_bt_scandel: bad operation '%d'", op);
|
||||
/* NOTREACHED */
|
||||
}
|
||||
so->btso_curbuf = buf;
|
||||
@@ -179,7 +179,7 @@ _bt_scandel(IndexScanDesc scan, int op, BlockNumber blkno, OffsetNumber offno)
|
||||
_bt_step(scan, &buf, BackwardScanDirection);
|
||||
break;
|
||||
default:
|
||||
elog(WARN, "_bt_scandel: bad operation '%d'", op);
|
||||
elog(ABORT, "_bt_scandel: bad operation '%d'", op);
|
||||
/* NOTREACHED */
|
||||
}
|
||||
so->btso_mrkbuf = buf;
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtsearch.c,v 1.27 1997/10/22 19:02:52 vadim Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtsearch.c,v 1.28 1998/01/05 03:29:53 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -617,7 +617,7 @@ _bt_compare(Relation rel,
|
||||
*/
|
||||
if (!P_RIGHTMOST(opaque))
|
||||
{
|
||||
elog(WARN, "_bt_compare: invalid comparison to high key");
|
||||
elog(ABORT, "_bt_compare: invalid comparison to high key");
|
||||
}
|
||||
|
||||
#if 0
|
||||
@@ -839,7 +839,7 @@ _bt_first(IndexScanDesc scan, ScanDirection dir)
|
||||
/* _bt_orderkeys disallows it, but it's place to add some code latter */
|
||||
if (so->keyData[0].sk_flags & SK_ISNULL)
|
||||
{
|
||||
elog(WARN, "_bt_first: btree doesn't support is(not)null, yet");
|
||||
elog(ABORT, "_bt_first: btree doesn't support is(not)null, yet");
|
||||
return ((RetrieveIndexResult) NULL);
|
||||
}
|
||||
proc = index_getprocid(rel, 1, BTORDER_PROC);
|
||||
@@ -1331,7 +1331,7 @@ _bt_twostep(IndexScanDesc scan, Buffer *bufP, ScanDirection dir)
|
||||
* us up less often since they're only done by the vacuum daemon.
|
||||
*/
|
||||
|
||||
elog(WARN, "btree synchronization error: concurrent update botched scan");
|
||||
elog(ABORT, "btree synchronization error: concurrent update botched scan");
|
||||
|
||||
return (false);
|
||||
}
|
||||
@@ -1416,7 +1416,7 @@ _bt_endpoint(IndexScanDesc scan, ScanDirection dir)
|
||||
if (ScanDirectionIsForward(dir))
|
||||
{
|
||||
if (!P_LEFTMOST(opaque))/* non-leftmost page ? */
|
||||
elog(WARN, "_bt_endpoint: leftmost page (%u) has not leftmost flag", blkno);
|
||||
elog(ABORT, "_bt_endpoint: leftmost page (%u) has not leftmost flag", blkno);
|
||||
start = P_RIGHTMOST(opaque) ? P_HIKEY : P_FIRSTKEY;
|
||||
|
||||
/*
|
||||
@@ -1440,7 +1440,7 @@ _bt_endpoint(IndexScanDesc scan, ScanDirection dir)
|
||||
if (PageIsEmpty(page))
|
||||
{
|
||||
if (start != P_HIKEY) /* non-rightmost page */
|
||||
elog(WARN, "_bt_endpoint: non-rightmost page (%u) is empty", blkno);
|
||||
elog(ABORT, "_bt_endpoint: non-rightmost page (%u) is empty", blkno);
|
||||
|
||||
/*
|
||||
* It's left- & right- most page - root page, - and it's
|
||||
@@ -1512,7 +1512,7 @@ _bt_endpoint(IndexScanDesc scan, ScanDirection dir)
|
||||
}
|
||||
else
|
||||
{
|
||||
elog(WARN, "Illegal scan direction %d", dir);
|
||||
elog(ABORT, "Illegal scan direction %d", dir);
|
||||
}
|
||||
|
||||
btitem = (BTItem) PageGetItem(page, PageGetItemId(page, start));
|
||||
|
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Id: nbtsort.c,v 1.24 1997/09/18 20:19:53 momjian Exp $
|
||||
* $Id: nbtsort.c,v 1.25 1998/01/05 03:29:55 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
*
|
||||
@@ -212,7 +212,7 @@ _bt_isortcmp(BTSortKey *k1, BTSortKey *k2)
|
||||
if (_bt_inspool->isunique && !equal_isnull)
|
||||
{
|
||||
_bt_spooldestroy((void *) _bt_inspool);
|
||||
elog(WARN, "Cannot create unique index. Table contains non-unique values");
|
||||
elog(ABORT, "Cannot create unique index. Table contains non-unique values");
|
||||
}
|
||||
return (0); /* 1 = 2 */
|
||||
}
|
||||
@@ -333,7 +333,7 @@ _bt_pqadd(BTPriQueue *q, BTPriQueueElem *e)
|
||||
|
||||
if (q->btpq_nelem >= MAXELEM)
|
||||
{
|
||||
elog(WARN, "_bt_pqadd: queue overflow");
|
||||
elog(ABORT, "_bt_pqadd: queue overflow");
|
||||
}
|
||||
|
||||
child = q->btpq_nelem++;
|
||||
@@ -426,7 +426,7 @@ _bt_tapecreate(char *fname)
|
||||
|
||||
if (tape == (BTTapeBlock *) NULL)
|
||||
{
|
||||
elog(WARN, "_bt_tapecreate: out of memory");
|
||||
elog(ABORT, "_bt_tapecreate: out of memory");
|
||||
}
|
||||
|
||||
tape->bttb_magic = BTTAPEMAGIC;
|
||||
@@ -563,7 +563,7 @@ _bt_spoolinit(Relation index, int ntapes, bool isunique)
|
||||
|
||||
if (btspool == (BTSpool *) NULL || fname == (char *) NULL)
|
||||
{
|
||||
elog(WARN, "_bt_spoolinit: out of memory");
|
||||
elog(ABORT, "_bt_spoolinit: out of memory");
|
||||
}
|
||||
MemSet((char *) btspool, 0, sizeof(BTSpool));
|
||||
btspool->bts_ntapes = ntapes;
|
||||
@@ -577,7 +577,7 @@ _bt_spoolinit(Relation index, int ntapes, bool isunique)
|
||||
if (btspool->bts_itape == (BTTapeBlock **) NULL ||
|
||||
btspool->bts_otape == (BTTapeBlock **) NULL)
|
||||
{
|
||||
elog(WARN, "_bt_spoolinit: out of memory");
|
||||
elog(ABORT, "_bt_spoolinit: out of memory");
|
||||
}
|
||||
|
||||
for (i = 0; i < ntapes; ++i)
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtutils.c,v 1.15 1997/09/18 20:19:55 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtutils.c,v 1.16 1998/01/05 03:29:56 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -119,7 +119,7 @@ _bt_orderkeys(Relation relation, BTScanOpaque so)
|
||||
|
||||
cur = &key[0];
|
||||
if (cur->sk_attno != 1)
|
||||
elog(WARN, "_bt_orderkeys: key(s) for attribute 1 missed");
|
||||
elog(ABORT, "_bt_orderkeys: key(s) for attribute 1 missed");
|
||||
|
||||
if (numberOfKeys == 1)
|
||||
{
|
||||
@@ -159,7 +159,7 @@ _bt_orderkeys(Relation relation, BTScanOpaque so)
|
||||
{
|
||||
if (cur->sk_attno != attno + 1 && i < numberOfKeys)
|
||||
{
|
||||
elog(WARN, "_bt_orderkeys: key(s) for attribute %d missed", attno + 1);
|
||||
elog(ABORT, "_bt_orderkeys: key(s) for attribute %d missed", attno + 1);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -296,7 +296,7 @@ _bt_formitem(IndexTuple itup)
|
||||
/*
|
||||
* see comments in btbuild
|
||||
*
|
||||
* if (itup->t_info & INDEX_NULL_MASK) elog(WARN, "btree indices cannot
|
||||
* if (itup->t_info & INDEX_NULL_MASK) elog(ABORT, "btree indices cannot
|
||||
* include null keys");
|
||||
*/
|
||||
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtproc.c,v 1.12 1997/09/18 20:19:56 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtproc.c,v 1.13 1998/01/05 03:29:59 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -29,7 +29,7 @@ rt_box_union(BOX *a, BOX *b)
|
||||
BOX *n;
|
||||
|
||||
if ((n = (BOX *) palloc(sizeof(*n))) == (BOX *) NULL)
|
||||
elog(WARN, "Cannot allocate box for union");
|
||||
elog(ABORT, "Cannot allocate box for union");
|
||||
|
||||
n->high.x = Max(a->high.x, b->high.x);
|
||||
n->high.y = Max(a->high.y, b->high.y);
|
||||
@@ -45,7 +45,7 @@ rt_box_inter(BOX *a, BOX *b)
|
||||
BOX *n;
|
||||
|
||||
if ((n = (BOX *) palloc(sizeof(*n))) == (BOX *) NULL)
|
||||
elog(WARN, "Cannot allocate box for union");
|
||||
elog(ABORT, "Cannot allocate box for union");
|
||||
|
||||
n->high.x = Min(a->high.x, b->high.x);
|
||||
n->high.y = Min(a->high.y, b->high.y);
|
||||
@@ -94,7 +94,7 @@ rt_poly_union(POLYGON *a, POLYGON *b)
|
||||
p = (POLYGON *) PALLOCTYPE(POLYGON);
|
||||
|
||||
if (!PointerIsValid(p))
|
||||
elog(WARN, "Cannot allocate polygon for union");
|
||||
elog(ABORT, "Cannot allocate polygon for union");
|
||||
|
||||
MemSet((char *) p, 0, sizeof(POLYGON)); /* zero any holes */
|
||||
p->size = sizeof(POLYGON);
|
||||
@@ -136,7 +136,7 @@ rt_poly_inter(POLYGON *a, POLYGON *b)
|
||||
p = (POLYGON *) PALLOCTYPE(POLYGON);
|
||||
|
||||
if (!PointerIsValid(p))
|
||||
elog(WARN, "Cannot allocate polygon for intersection");
|
||||
elog(ABORT, "Cannot allocate polygon for intersection");
|
||||
|
||||
MemSet((char *) p, 0, sizeof(POLYGON)); /* zero any holes */
|
||||
p->size = sizeof(POLYGON);
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtree.c,v 1.19 1997/11/20 23:20:26 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtree.c,v 1.20 1998/01/05 03:30:02 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -125,7 +125,7 @@ rtbuild(Relation heap,
|
||||
*/
|
||||
|
||||
if (oldPred == NULL && (nb = RelationGetNumberOfBlocks(index)) != 0)
|
||||
elog(WARN, "%s already contains data", index->rd_rel->relname.data);
|
||||
elog(ABORT, "%s already contains data", index->rd_rel->relname.data);
|
||||
|
||||
/* initialize the root page (if this is a new index) */
|
||||
if (oldPred == NULL)
|
||||
@@ -664,7 +664,7 @@ rtintinsert(Relation r,
|
||||
*/
|
||||
|
||||
if (IndexTupleSize(old) != IndexTupleSize(ltup))
|
||||
elog(WARN, "Variable-length rtree keys are not supported.");
|
||||
elog(ABORT, "Variable-length rtree keys are not supported.");
|
||||
|
||||
/* install pointer to left child */
|
||||
memmove(old, ltup, IndexTupleSize(ltup));
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtscan.c,v 1.13 1997/09/08 21:41:40 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtscan.c,v 1.14 1998/01/05 03:30:05 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -85,7 +85,7 @@ rtrescan(IndexScanDesc s, bool fromEnd, ScanKey key)
|
||||
|
||||
if (!IndexScanIsValid(s))
|
||||
{
|
||||
elog(WARN, "rtrescan: invalid scan.");
|
||||
elog(ABORT, "rtrescan: invalid scan.");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -284,7 +284,7 @@ rtdropscan(IndexScanDesc s)
|
||||
}
|
||||
|
||||
if (l == (RTScanList) NULL)
|
||||
elog(WARN, "rtree scan list corrupted -- cannot find 0x%lx", s);
|
||||
elog(ABORT, "rtree scan list corrupted -- cannot find 0x%lx", s);
|
||||
|
||||
if (prev == (RTScanList) NULL)
|
||||
RTScans = l->rtsl_next;
|
||||
@@ -400,7 +400,7 @@ adjustiptr(IndexScanDesc s,
|
||||
break;
|
||||
|
||||
default:
|
||||
elog(WARN, "Bad operation in rtree scan adjust: %d", op);
|
||||
elog(ABORT, "Bad operation in rtree scan adjust: %d", op);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/transam/transam.c,v 1.14 1997/11/02 15:24:42 vadim Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/transam/transam.c,v 1.15 1998/01/05 03:30:07 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* This file contains the high level access-method interface to the
|
||||
@@ -183,7 +183,7 @@ TransactionLogTest(TransactionId transactionId, /* transaction id to test */
|
||||
* here the block didn't contain the information we wanted
|
||||
* ----------------
|
||||
*/
|
||||
elog(WARN, "TransactionLogTest: failed to get xidstatus");
|
||||
elog(ABORT, "TransactionLogTest: failed to get xidstatus");
|
||||
|
||||
/*
|
||||
* so lint is happy...
|
||||
@@ -308,7 +308,7 @@ TransRecover(Relation logRelation)
|
||||
*/
|
||||
TransGetLastRecordedTransaction(logRelation, logLastXid, &fail);
|
||||
if (fail == true)
|
||||
elog(WARN, "TransRecover: failed TransGetLastRecordedTransaction");
|
||||
elog(ABORT, "TransRecover: failed TransGetLastRecordedTransaction");
|
||||
|
||||
/* ----------------
|
||||
* next get the "last" and "next" variables
|
||||
@@ -322,7 +322,7 @@ TransRecover(Relation logRelation)
|
||||
* ----------------
|
||||
*/
|
||||
if (TransactionIdIsLessThan(varNextXid, logLastXid))
|
||||
elog(WARN, "TransRecover: varNextXid < logLastXid");
|
||||
elog(ABORT, "TransRecover: varNextXid < logLastXid");
|
||||
|
||||
/* ----------------
|
||||
* intregity test (2)
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/transam/Attic/transsup.c,v 1.14 1997/11/02 15:24:44 vadim Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/transam/Attic/transsup.c,v 1.15 1998/01/05 03:30:10 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* This file contains support functions for the high
|
||||
@@ -68,7 +68,7 @@ TransComputeBlockNumber(Relation relation, /* relation to test */
|
||||
if (relation == LogRelation)
|
||||
itemsPerBlock = TP_NumXidStatusPerBlock;
|
||||
else
|
||||
elog(WARN, "TransComputeBlockNumber: unknown relation");
|
||||
elog(ABORT, "TransComputeBlockNumber: unknown relation");
|
||||
|
||||
/* ----------------
|
||||
* warning! if the transaction id's get too large
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/transam/varsup.c,v 1.13 1997/11/02 15:24:45 vadim Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/transam/varsup.c,v 1.14 1998/01/05 03:30:12 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -69,7 +69,7 @@ VariableRelationGetNextXid(TransactionId *xidP)
|
||||
if (!BufferIsValid(buf))
|
||||
{
|
||||
SpinRelease(OidGenLockId);
|
||||
elog(WARN, "VariableRelationGetNextXid: ReadBuffer failed");
|
||||
elog(ABORT, "VariableRelationGetNextXid: ReadBuffer failed");
|
||||
}
|
||||
|
||||
var = (VariableRelationContents) BufferGetBlock(buf);
|
||||
@@ -112,7 +112,7 @@ VariableRelationPutNextXid(TransactionId xid)
|
||||
if (!BufferIsValid(buf))
|
||||
{
|
||||
SpinRelease(OidGenLockId);
|
||||
elog(WARN, "VariableRelationPutNextXid: ReadBuffer failed");
|
||||
elog(ABORT, "VariableRelationPutNextXid: ReadBuffer failed");
|
||||
}
|
||||
|
||||
var = (VariableRelationContents) BufferGetBlock(buf);
|
||||
@@ -164,7 +164,7 @@ VariableRelationGetNextOid(Oid *oid_return)
|
||||
if (!BufferIsValid(buf))
|
||||
{
|
||||
SpinRelease(OidGenLockId);
|
||||
elog(WARN, "VariableRelationGetNextXid: ReadBuffer failed");
|
||||
elog(ABORT, "VariableRelationGetNextXid: ReadBuffer failed");
|
||||
}
|
||||
|
||||
var = (VariableRelationContents) BufferGetBlock(buf);
|
||||
@@ -224,7 +224,7 @@ VariableRelationPutNextOid(Oid *oidP)
|
||||
if (!PointerIsValid(oidP))
|
||||
{
|
||||
SpinRelease(OidGenLockId);
|
||||
elog(WARN, "VariableRelationPutNextOid: invalid oid pointer");
|
||||
elog(ABORT, "VariableRelationPutNextOid: invalid oid pointer");
|
||||
}
|
||||
|
||||
/* ----------------
|
||||
@@ -237,7 +237,7 @@ VariableRelationPutNextOid(Oid *oidP)
|
||||
if (!BufferIsValid(buf))
|
||||
{
|
||||
SpinRelease(OidGenLockId);
|
||||
elog(WARN, "VariableRelationPutNextOid: ReadBuffer failed");
|
||||
elog(ABORT, "VariableRelationPutNextOid: ReadBuffer failed");
|
||||
}
|
||||
|
||||
var = (VariableRelationContents) BufferGetBlock(buf);
|
||||
|
@@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.17 1997/11/02 15:24:46 vadim Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/access/transam/xact.c,v 1.18 1998/01/05 03:30:13 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Transaction aborts can now occur two ways:
|
||||
@@ -497,7 +497,7 @@ CommandCounterIncrement()
|
||||
if (CurrentTransactionStateData.commandId == FirstCommandId)
|
||||
{
|
||||
CommandIdCounterOverflowFlag = true;
|
||||
elog(WARN, "You may only have 2^32-1 commands per transaction");
|
||||
elog(ABORT, "You may only have 2^32-1 commands per transaction");
|
||||
}
|
||||
|
||||
CurrentTransactionStateData.scanCommandId =
|
||||
|
Reference in New Issue
Block a user