After further testing, this test case should be refined to throw
NO_DATA_FOUND errors from the INTO STRICT clause to produce the memory leak.

In pl_exec.c, exec_stmt_execsql does not free the SPI_tuptable by calling
SPI_freetuptable before the ereport.  Attached is a patch to 9.2-STABLE
that seems to resolve it.

Attachment: pl_exec.diff
Description: Binary data

Attachment: valgrind.out
Description: Binary data

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply via email to