Andres Freund writes:
> On 2018-02-10 18:37:17 +, Tom Lane wrote:
> CALL ptest1(substring(random()::text, 1, 1)); -- ok, volatile arg
> At first I was gosh darned confused, this really didn't seem likely to
> be an LLVM induced failure. And it turns out it isn't. If the value
> returned by
On 2018-02-10 18:37:17 +, Tom Lane wrote:
> Avoid premature free of pass-by-reference CALL arguments.
> src/test/regress/expected/create_procedure.out | 12 +++
> src/test/regress/sql/create_procedure.sql | 4 +++-
> 3 files changed, 33 insertions(+), 11 deletions(-)
There's a re
Avoid premature free of pass-by-reference CALL arguments.
Prematurely freeing the EState used to evaluate CALL arguments led, in some
cases, to passing dangling pointers to the procedure. This was masked in
trivial cases because the argument pointers would point to Const nodes in
the original exp