diff options
author | Andres Freund <andres@anarazel.de> | 2015-09-22 11:05:48 +0200 |
---|---|---|
committer | Andres Freund <andres@anarazel.de> | 2015-09-22 11:14:14 +0200 |
commit | 98d5b084d23b0304569ef2c1b4794754166cf0a5 (patch) | |
tree | c9f4d742c48f7bf9139d82e59049cc3500f7a2f5 /src | |
parent | d9cb34abb40c547325dbf24e8986698dffc9ffa8 (diff) | |
download | postgresql-98d5b084d23b0304569ef2c1b4794754166cf0a5.tar.gz postgresql-98d5b084d23b0304569ef2c1b4794754166cf0a5.zip |
Correct value of LW_SHARED_MASK.
The previous wrong value lead to wrong LOCK_DEBUG output, never showing
any shared lock holders.
Reported-By: Alexander Korotkov
Discussion: CAPpHfdsPmWqz9FB0AnxJrwp1=KLF0n=-iB+QvR0Q8GSmpFVdUQ@mail.gmail.com
Backpatch: 9.5, where the bug was introduced.
Diffstat (limited to 'src')
-rw-r--r-- | src/backend/storage/lmgr/lwlock.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/backend/storage/lmgr/lwlock.c b/src/backend/storage/lmgr/lwlock.c index 9179d1b356b..fd4b479f10c 100644 --- a/src/backend/storage/lmgr/lwlock.c +++ b/src/backend/storage/lmgr/lwlock.c @@ -107,7 +107,7 @@ extern slock_t *ShmemLock; #define LW_LOCK_MASK ((uint32) ((1 << 25)-1)) /* Must be greater than MAX_BACKENDS - which is 2^23-1, so we're fine. */ -#define LW_SHARED_MASK ((uint32)(1 << 23)) +#define LW_SHARED_MASK ((uint32) ((1 << 24)-1)) /* * This is indexed by tranche ID and stores metadata for all tranches known |