1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-05 07:21:24 +03:00

Modify hash_create() to elog(ERROR) if an error occurs, rather than

returning a NULL pointer (some callers remembered to check the return
value, but some did not -- it is safer to just bail out).

Also, cleanup pgstat.c to use elog(ERROR) rather than elog(LOG) followed
by exit().
This commit is contained in:
Neil Conway
2004-10-25 00:46:43 +00:00
parent 346aff04be
commit 8ec05b28b7
9 changed files with 49 additions and 175 deletions

View File

@ -10,7 +10,7 @@
* Copyright (c) 2002-2004, PostgreSQL Global Development Group
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/commands/prepare.c,v 1.32 2004/09/13 20:06:29 tgl Exp $
* $PostgreSQL: pgsql/src/backend/commands/prepare.c,v 1.33 2004/10/25 00:46:40 neilc Exp $
*
*-------------------------------------------------------------------------
*/
@ -264,9 +264,6 @@ InitQueryHashTable(void)
32,
&hash_ctl,
HASH_ELEM);
if (!prepared_queries)
elog(ERROR, "could not create hash table");
}
/*