aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/transam/commit_ts.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2016-10-23 15:01:24 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2016-10-23 15:01:24 -0400
commit6292c2339186bac215bab5a1f01370f9735582c1 (patch)
tree4d5b53e2e3caa66b8823d857053a806b61e4cda3 /src/backend/access/transam/commit_ts.c
parenteade082b122889eaf92eb806b8b6799160a25256 (diff)
downloadpostgresql-6292c2339186bac215bab5a1f01370f9735582c1.tar.gz
postgresql-6292c2339186bac215bab5a1f01370f9735582c1.zip
Avoid testing tuple visibility without buffer lock in RI_FKey_check().
Despite the argumentation I wrote in commit 7a2fe85b0, it's unsafe to do this, because in corner cases it's possible for HeapTupleSatisfiesSelf to try to set hint bits on the target tuple; and at least since 8.2 we have required the buffer content lock to be held while setting hint bits. The added regression test exercises one such corner case. Unpatched, it causes an assertion failure in assert-enabled builds, or otherwise would cause a hint bit change in a buffer we don't hold lock on, which given the right race condition could result in checksum failures or other data consistency problems. The odds of a problem in the field are probably pretty small, but nonetheless back-patch to all supported branches. Report: <19391.1477244876@sss.pgh.pa.us>
Diffstat (limited to 'src/backend/access/transam/commit_ts.c')
0 files changed, 0 insertions, 0 deletions