]> granicus.if.org Git - postgresql/commit
Fetch XIDs atomically during vac_truncate_clog().
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 24 May 2016 19:47:51 +0000 (15:47 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 24 May 2016 19:47:51 +0000 (15:47 -0400)
commit5551dac59c0601b49d57a3f897fb0a6d581e58ac
tree16114f6cba862c73b2e77ad7efa0f948b84a8178
parentfe1731fca27008836f2208f4be8c22acf8ec1f67
Fetch XIDs atomically during vac_truncate_clog().

Because vac_update_datfrozenxid() updates datfrozenxid and datminmxid
in-place, it's unsafe to assume that successive reads of those values will
give consistent results.  Fetch each one just once to ensure sane behavior
in the minimum calculation.  Noted while reviewing Alexander Korotkov's
patch in the same area.

Discussion: <8564.1464116473@sss.pgh.pa.us>
src/backend/commands/vacuum.c