]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Fix lock release for role membership grants in DROP OWNED BY. master github/master
authorJeff Davis <jdavis@postgresql.org>
Mon, 3 Aug 2026 19:21:05 +0000 (12:21 -0700)
committerJeff Davis <jdavis@postgresql.org>
Mon, 3 Aug 2026 19:21:05 +0000 (12:21 -0700)
commitb48caa7dfde8991ee09226593c381bd3442297dc
tree242ef6933107a3ed07315d76796a1c3476c487a4
parent6a6e99f859db1163a3646eaf8e47f865312dfc07
Fix lock release for role membership grants in DROP OWNED BY.

Commit 6566133c5f5 added a case for AuthMemRelationId in
AcquireDeletionLock(), but not ReleaseDeletionLock(). The fall-through
case would go to UnlockDatabaseObject(), which would raise a WARNING;
and the lock would be retained until the end of the transaction.

Add the missing branch.

Discussion: https://postgr.es/m/2487ddcd737d4fc8e408e87aa9ad4365eed3bbb3.camel@j-davis.com
Backpatch-through: 16
src/backend/catalog/dependency.c
src/test/isolation/expected/drop-owned-grant.out [new file with mode: 0644]
src/test/isolation/isolation_schedule
src/test/isolation/specs/drop-owned-grant.spec [new file with mode: 0644]