Fix parallel amvacuumcleanup safety bug.
authorPeter Geoghegan <pg@bowt.ie>
Wed, 3 Nov 2021 02:52:11 +0000 (19:52 -0700)
committerPeter Geoghegan <pg@bowt.ie>
Wed, 3 Nov 2021 02:52:11 +0000 (19:52 -0700)
commitc59278a1aa5ef2ee8a6d5d83bd987a7ce5c89e84
tree89a6c3f117c40c69dd7988ddabecd01f0e7fae27
parent24f9e49e430b4173d75a570e06abef8e3fd12c5e
Fix parallel amvacuumcleanup safety bug.

Commit b4af70cb inverted the return value of the function
parallel_processing_is_safe(), but missed the amvacuumcleanup test.
Index AMs that don't support parallel cleanup at all were affected.

The practical consequences of this bug were not very serious.  Hash
indexes are affected, but since they just return the number of blocks
during hashvacuumcleanup anyway, it can't have had much impact.

Author: Masahiko Sawada <sawada.mshk@gmail.com>
Discussion: https://postgr.es/m/CAD21AoA-Em+aeVPmBbL_s1V-ghsJQSxYL-i3JP8nTfPiD1wjKw@mail.gmail.com
Backpatch: 14-, where commit b4af70cb appears.
src/backend/access/heap/vacuumlazy.c