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

@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_init.c,v 1.15 1997/11/02 15:25:36 vadim Exp $
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_init.c,v 1.16 1998/01/05 03:32:51 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -155,10 +155,10 @@ InitBufferPool(IPCKey key)
*/
if (sizeof(struct sbufdesc) != PADDED_SBUFDESC_SIZE ||
sizeof(struct sbufdesc_unpadded) > PADDED_SBUFDESC_SIZE)
elog(WARN, "Internal error: sbufdesc does not have the proper size, "
elog(ABORT, "Internal error: sbufdesc does not have the proper size, "
"contact the Postgres developers");
if (sizeof(struct sbufdesc_unpadded) <= PADDED_SBUFDESC_SIZE / 2)
elog(WARN, "Internal error: sbufdesc is greatly over-sized, "
elog(ABORT, "Internal error: sbufdesc is greatly over-sized, "
"contact the Postgres developers");
Data_Descriptors = NBuffers;

View File

@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_table.c,v 1.8 1997/09/08 21:46:46 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_table.c,v 1.9 1998/01/05 03:32:52 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -87,7 +87,7 @@ BufTableLookup(BufferTag *tagPtr)
if (!result)
{
elog(WARN, "BufTableLookup: BufferLookup table corrupted");
elog(ABORT, "BufTableLookup: BufferLookup table corrupted");
return (NULL);
}
if (!found)
@@ -122,7 +122,7 @@ BufTableDelete(BufferDesc *buf)
if (!(result && found))
{
elog(WARN, "BufTableDelete: BufferLookup table corrupted");
elog(ABORT, "BufTableDelete: BufferLookup table corrupted");
return (FALSE);
}
@@ -145,14 +145,14 @@ BufTableInsert(BufferDesc *buf)
if (!result)
{
Assert(0);
elog(WARN, "BufTableInsert: BufferLookup table corrupted");
elog(ABORT, "BufTableInsert: BufferLookup table corrupted");
return (FALSE);
}
/* found something else in the table ! */
if (found)
{
Assert(0);
elog(WARN, "BufTableInsert: BufferLookup table corrupted");
elog(ABORT, "BufTableInsert: BufferLookup table corrupted");
return (FALSE);
}

View File

@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/bufmgr.c,v 1.29 1997/11/21 18:11:04 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/bufmgr.c,v 1.30 1998/01/05 03:32:54 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -444,7 +444,7 @@ BufferAlloc(Relation reln,
/*
* But it can return buf == NULL if we are in aborting transaction
* now and so elog(WARN,...) in GetFreeBuffer will not abort
* now and so elog(ABORT,...) in GetFreeBuffer will not abort
* again.
*/
if (buf == NULL)
@@ -834,7 +834,7 @@ FlushBuffer(Buffer buffer, bool release)
if (status == SM_FAIL)
{
elog(WARN, "FlushBuffer: cannot flush block %u of the relation %s",
elog(ABORT, "FlushBuffer: cannot flush block %u of the relation %s",
bufHdr->tag.blockNum, bufHdr->sb_relname);
return (STATUS_ERROR);
}
@@ -1009,7 +1009,7 @@ BufferSync()
UnpinBuffer(bufHdr);
if (bufHdr->flags & BM_IO_ERROR)
{
elog(WARN, "BufferSync: write error %u for %s",
elog(ABORT, "BufferSync: write error %u for %s",
bufHdr->tag.blockNum, bufHdr->sb_relname);
}
if (reln != (Relation) NULL)
@@ -1054,7 +1054,7 @@ BufferSync()
if (status == SM_FAIL)
{
bufHdr->flags |= BM_IO_ERROR;
elog(WARN, "BufferSync: cannot write %u for %s",
elog(ABORT, "BufferSync: cannot write %u for %s",
bufHdr->tag.blockNum, bufHdr->sb_relname);
}
BufferFlushCount++;

View File

@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/freelist.c,v 1.7 1997/09/08 20:56:47 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/freelist.c,v 1.8 1998/01/05 03:32:56 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -189,7 +189,7 @@ GetFreeBuffer()
{
/* queue is empty. All buffers in the buffer pool are pinned. */
elog(WARN, "out of free buffers: time to abort !\n");
elog(ABORT, "out of free buffers: time to abort !\n");
return (NULL);
}
buf = &(BufferDescriptors[SharedFreeList->freeNext]);

View File

@@ -15,7 +15,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/localbuf.c,v 1.14 1997/11/21 18:11:07 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/storage/buffer/localbuf.c,v 1.15 1998/01/05 03:32:58 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -110,7 +110,7 @@ LocalBufferAlloc(Relation reln, BlockNumber blockNum, bool *foundPtr)
}
}
if (bufHdr == NULL)
elog(WARN, "no empty local buffer.");
elog(ABORT, "no empty local buffer.");
/*
* this buffer is not referenced but it might still be dirty (the last