mirror of
https://github.com/postgres/postgres.git
synced 2025-11-06 07:49:08 +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:
@@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/storage/lmgr/lock.c,v 1.142 2004/09/29 15:15:55 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/storage/lmgr/lock.c,v 1.143 2004/10/25 00:46:41 neilc Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Outside modules can create a lock table and acquire/release
|
||||
@@ -335,9 +335,6 @@ LockMethodTableInit(const char *tabName,
|
||||
&info,
|
||||
hash_flags);
|
||||
|
||||
if (!LockMethodLocalHash[lockmethodid])
|
||||
elog(FATAL, "could not initialize lock table \"%s\"", tabName);
|
||||
|
||||
pfree(shmemName);
|
||||
|
||||
return lockmethodid;
|
||||
|
||||
Reference in New Issue
Block a user