pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. 5+ messages / 1 participants [nested] [flat]
* pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. @ 2021-06-18 16:09 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 5+ messages in thread From: Tom Lane @ 2021-06-18 16:09 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. This works fine in the "simple Query" code path; but if the statement is in the plan cache then it's corrupted for future re-execution. Apply copyObject() to protect the original tree from modification, as we've done elsewhere. This narrow fix is applied only to the back branches. In HEAD, the problem was fixed more generally by commit 7c337b6b5; but that changed ProcessUtility's API, so it's infeasible to back-patch. Per bug #17053 from Charles Samborski. Discussion: https://postgr.es/m/931771.1623893989@sss.pgh.pa.us Discussion: https://postgr.es/m/17053-3ca3f501bbc212b4@postgresql.org Branch ------ REL_13_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/102f31a208b85aec542fc93f73a222d98d551694 Modified Files -------------- src/backend/commands/typecmds.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
* pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. @ 2021-06-18 16:09 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 5+ messages in thread From: Tom Lane @ 2021-06-18 16:09 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. This works fine in the "simple Query" code path; but if the statement is in the plan cache then it's corrupted for future re-execution. Apply copyObject() to protect the original tree from modification, as we've done elsewhere. This narrow fix is applied only to the back branches. In HEAD, the problem was fixed more generally by commit 7c337b6b5; but that changed ProcessUtility's API, so it's infeasible to back-patch. Per bug #17053 from Charles Samborski. Discussion: https://postgr.es/m/931771.1623893989@sss.pgh.pa.us Discussion: https://postgr.es/m/17053-3ca3f501bbc212b4@postgresql.org Branch ------ REL_12_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/b2c740c426daca2e43a2c86ff19661baf05ad00a Modified Files -------------- src/backend/commands/typecmds.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
* pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. @ 2021-06-18 16:09 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 5+ messages in thread From: Tom Lane @ 2021-06-18 16:09 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. This works fine in the "simple Query" code path; but if the statement is in the plan cache then it's corrupted for future re-execution. Apply copyObject() to protect the original tree from modification, as we've done elsewhere. This narrow fix is applied only to the back branches. In HEAD, the problem was fixed more generally by commit 7c337b6b5; but that changed ProcessUtility's API, so it's infeasible to back-patch. Per bug #17053 from Charles Samborski. Discussion: https://postgr.es/m/931771.1623893989@sss.pgh.pa.us Discussion: https://postgr.es/m/17053-3ca3f501bbc212b4@postgresql.org Branch ------ REL_11_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/4b8b3562e1e6e5b4abd5e9326f71af73e98dc604 Modified Files -------------- src/backend/commands/typecmds.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
* pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. @ 2021-06-18 16:09 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 5+ messages in thread From: Tom Lane @ 2021-06-18 16:09 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. This works fine in the "simple Query" code path; but if the statement is in the plan cache then it's corrupted for future re-execution. Apply copyObject() to protect the original tree from modification, as we've done elsewhere. This narrow fix is applied only to the back branches. In HEAD, the problem was fixed more generally by commit 7c337b6b5; but that changed ProcessUtility's API, so it's infeasible to back-patch. Per bug #17053 from Charles Samborski. Discussion: https://postgr.es/m/931771.1623893989@sss.pgh.pa.us Discussion: https://postgr.es/m/17053-3ca3f501bbc212b4@postgresql.org Branch ------ REL_10_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/f172438ef6ff7fa374edeaee423241410c97566c Modified Files -------------- src/backend/commands/typecmds.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
* pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. @ 2021-06-18 16:09 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 5+ messages in thread From: Tom Lane @ 2021-06-18 16:09 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. This works fine in the "simple Query" code path; but if the statement is in the plan cache then it's corrupted for future re-execution. Apply copyObject() to protect the original tree from modification, as we've done elsewhere. This narrow fix is applied only to the back branches. In HEAD, the problem was fixed more generally by commit 7c337b6b5; but that changed ProcessUtility's API, so it's infeasible to back-patch. Per bug #17053 from Charles Samborski. Discussion: https://postgr.es/m/931771.1623893989@sss.pgh.pa.us Discussion: https://postgr.es/m/17053-3ca3f501bbc212b4@postgresql.org Branch ------ REL9_6_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/1a3d30255a4e821445927ca0949f00364de660fd Modified Files -------------- src/backend/commands/typecmds.c | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) ^ permalink raw reply [nested|flat] 5+ messages in thread
end of thread, other threads:[~2021-06-18 16:09 UTC | newest] Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2021-06-18 16:09 pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. Tom Lane <tgl@sss.pgh.pa.us> 2021-06-18 16:09 pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. Tom Lane <tgl@sss.pgh.pa.us> 2021-06-18 16:09 pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. Tom Lane <tgl@sss.pgh.pa.us> 2021-06-18 16:09 pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. Tom Lane <tgl@sss.pgh.pa.us> 2021-06-18 16:09 pgsql: Avoid scribbling on input node tree in CREATE/ALTER DOMAIN. Tom Lane <tgl@sss.pgh.pa.us>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox