Fix corruption of pg_shdepend when copying deps from template database
Michael Paquier <michael@paquier.xyz>
Fix corruption of pg_shdepend when copying deps from template database Using for a new database a template database with shared dependencies that need to be copied over was causing a corruption of pg_shdepend because of an off-by-one computation error of the index number used for the values inserted with a slot. Issue introduced by e3931d0. Monitoring the rest of the code, there are no similar mistakes. Reported-by: Sven Klemm Author: Aleksander Alekseev Reviewed-by: Daniel Gustafsson, Michael Paquier Discussion: https://postgr.es/m/CAJ7c6TP0AowkUgNL6zcAK-s5HYsVHVBRWfu69FRubPpfwZGM9A@mail.gmail.com Backpatch-through: 14
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/catalog/pg_shdepend.c | modified | +7 −7 |
Discussion
- [PATCH] Fix memory corruption in pg_shdepend.c 24 messages · 2021-10-20 → 2021-10-28