Fix subscriber invalid memory access on DDL.
authorAmit Kapila <[email protected]>
Wed, 18 Dec 2019 02:57:41 +0000 (08:27 +0530)
committerAmit Kapila <[email protected]>
Wed, 18 Dec 2019 02:57:41 +0000 (08:27 +0530)
commitd6eca4958d78499b66aad9cf4b595b871c177e02
tree6f8db29e3083aa3b551d92b73e9c3e4b45c6a613
parent5c5a268c605b9040206a3174667c20056d8e6603
Fix subscriber invalid memory access on DDL.

This patch allows building the local relmap cache for a subscribed
relation after processing pending invalidation messages and potential
relcache updates.  Without this, the attributes in the local cache don't
tally with the updated relcache entry leading to invalid memory access.

Reported-by Jehan-Guillaume de Rorthais
Author: Jehan-Guillaume de Rorthais and Vignesh C
Reviewed-by: Amit Kapila
Backpatch-through: 10
Discussion: https://postgr.es/m/20191025175929.7e90dbf5@firost
src/backend/replication/logical/relation.c