summaryrefslogtreecommitdiff
path: root/src/backend/commands/dbcommands.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2000-11-12 20:51:52 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2000-11-12 20:51:52 +0000
commitebb0a2014930034a89ae5f4953b52c9afbf585ae (patch)
tree2c8126548b1737e6312c40aa9aecfe9f549f11cb /src/backend/commands/dbcommands.c
parentc48025e799dd51a78c82193bc9ce6c63d7e6681f (diff)
downloadpostgresql-ebb0a2014930034a89ae5f4953b52c9afbf585ae.tar.gz
Keep track of the last active slot in the shared ProcState array, so
that search loops only have to scan that far and not through all maxBackends entries. This eliminates a performance penalty for setting maxBackends much higher than the average number of active backends. Also, eliminate no-longer-used 'backend tag' concept. Remove setting of environment variables at backend start (except for CYR_RECODE), since none of them are being examined by the backend any longer.
Diffstat (limited to 'src/backend/commands/dbcommands.c')
-rw-r--r--src/backend/commands/dbcommands.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/commands/dbcommands.c b/src/backend/commands/dbcommands.c
index e2821d6237..2442679250 100644
--- a/src/backend/commands/dbcommands.c
+++ b/src/backend/commands/dbcommands.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.65 2000/11/08 23:24:24 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.66 2000/11/12 20:51:50 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -225,7 +225,7 @@ dropdb(const char *dbname)
/*
* Check for active backends in the target database.
*/
- if (DatabaseHasActiveBackends(db_id))
+ if (DatabaseHasActiveBackends(db_id, false))
{
heap_close(pgdbrel, AccessExclusiveLock);
elog(ERROR, "DROP DATABASE: database \"%s\" is being accessed by other users", dbname);