1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-29 10:41:53 +03:00

Rename 'holder' references to 'proclock' for PROCLOCK references, for

consistency.
This commit is contained in:
Bruce Momjian
2003-02-18 02:13:24 +00:00
parent cf55ee5758
commit 32cc6cbe23
6 changed files with 218 additions and 217 deletions

View File

@ -6,7 +6,7 @@
* Copyright (c) 2002, PostgreSQL Global Development Group
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/lockfuncs.c,v 1.7 2002/09/04 20:31:28 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/lockfuncs.c,v 1.8 2003/02/18 02:13:24 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -88,7 +88,7 @@ pg_lock_status(PG_FUNCTION_ARGS)
while (mystatus->currIdx < lockData->nelements)
{
PROCLOCK *holder;
PROCLOCK *proclock;
LOCK *lock;
PGPROC *proc;
bool granted;
@ -98,7 +98,7 @@ pg_lock_status(PG_FUNCTION_ARGS)
HeapTuple tuple;
Datum result;
holder = &(lockData->holders[mystatus->currIdx]);
proclock = &(lockData->proclocks[mystatus->currIdx]);
lock = &(lockData->locks[mystatus->currIdx]);
proc = &(lockData->procs[mystatus->currIdx]);
@ -110,10 +110,10 @@ pg_lock_status(PG_FUNCTION_ARGS)
granted = false;
for (mode = 0; mode < MAX_LOCKMODES; mode++)
{
if (holder->holding[mode] > 0)
if (proclock->holding[mode] > 0)
{
granted = true;
holder->holding[mode] = 0;
proclock->holding[mode] = 0;
break;
}
}
@ -124,7 +124,7 @@ pg_lock_status(PG_FUNCTION_ARGS)
*/
if (!granted)
{
if (proc->waitLock == (LOCK *) MAKE_PTR(holder->tag.lock))
if (proc->waitLock == (LOCK *) MAKE_PTR(proclock->tag.lock))
{
/* Yes, so report it with proper mode */
mode = proc->waitLockMode;