aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlvaro Herrera <alvherre@alvh.no-ip.org>2015-09-11 15:29:46 -0300
committerAlvaro Herrera <alvherre@alvh.no-ip.org>2015-09-11 15:29:46 -0300
commit5cd6538345858aec128945b58265a8d5560777dc (patch)
tree0541295030f10e0bb1a7fc1dd0eaf55198da4bd4 /src
parent5ddc72887a012f6a8b85707ef27d85c274faf53d (diff)
downloadpostgresql-5cd6538345858aec128945b58265a8d5560777dc.tar.gz
postgresql-5cd6538345858aec128945b58265a8d5560777dc.zip
Add missing ReleaseBuffer call in BRIN revmap code
I think this particular branch is actually dead, but the analysis to prove that is not trivial, so instead take the weasel way. Reported by Jinyu Zhang Backpatch to 9.5, where BRIN was introduced.
Diffstat (limited to 'src')
-rw-r--r--src/backend/access/brin/brin_revmap.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/backend/access/brin/brin_revmap.c b/src/backend/access/brin/brin_revmap.c
index 8c55f16f838..6ddcfda0a6c 100644
--- a/src/backend/access/brin/brin_revmap.c
+++ b/src/backend/access/brin/brin_revmap.c
@@ -432,6 +432,7 @@ revmap_physical_extend(BrinRevmap *revmap)
if (needLock)
UnlockRelationForExtension(irel, ExclusiveLock);
LockBuffer(revmap->rm_metaBuf, BUFFER_LOCK_UNLOCK);
+ ReleaseBuffer(buf);
return;
}
LockBuffer(buf, BUFFER_LOCK_EXCLUSIVE);