postgresql/src/test
Stephen Frost 6f8cb1e234 Make viewquery a copy in rewriteTargetView()
Rather than expect the Query returned by get_view_query() to be
read-only and then copy bits and pieces of it out, simply copy the
entire structure when we get it.  This addresses an issue where
AcquireRewriteLocks, which is called by acquireLocksOnSubLinks(),
scribbles on the parsetree passed in, which was actually an entry
in relcache, leading to segfaults with certain view definitions.
This also future-proofs us a bit for anyone adding more code to this
path.

The acquireLocksOnSubLinks() was added in commit c3e0ddd40.

Back-patch to 9.3 as that commit was.
2015-12-21 10:34:14 -05:00
..
examples Fix up .gitignore and cleanup actions in some src/test/ subdirectories. 2015-04-24 17:13:06 -04:00
isolation Fix errors in commit a04bb65f70. 2015-09-30 23:37:26 -04:00
locale Fix up .gitignore and cleanup actions in some src/test/ subdirectories. 2015-04-24 17:13:06 -04:00
mb Fix broken multibyte regression tests. 2015-08-09 11:05:53 +09:00
modules Message style improvements 2015-10-28 20:38:36 -04:00
perl Avoid odd portability problem in TestLib.pm's slurp_file function. 2015-12-08 16:58:05 -05:00
regress Make viewquery a copy in rewriteTargetView() 2015-12-21 10:34:14 -05:00
ssl Refactor Perl test code 2015-12-02 18:46:16 -03:00
thread Fix up .gitignore and cleanup actions in some src/test/ subdirectories. 2015-04-24 17:13:06 -04:00
Makefile Fix up .gitignore and cleanup actions in some src/test/ subdirectories. 2015-04-24 17:13:06 -04:00