diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2013-03-01 21:33:34 -0500 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2013-03-01 21:34:17 -0500 |
commit | a4d3a504e730c47ccee5082ee703082e42c8b5ce (patch) | |
tree | 3cb7e8696994d39dba6f2f4bf069b251ff05a80c /src/tools/pginclude/cpluspluscheck | |
parent | cd7d00ad65fab11496ad9990cfc145c06c6ee53d (diff) | |
download | postgresql-a4d3a504e730c47ccee5082ee703082e42c8b5ce.tar.gz postgresql-a4d3a504e730c47ccee5082ee703082e42c8b5ce.zip |
Eliminate memory leaks in plperl's spi_prepare() function.
Careless use of TopMemoryContext for I/O function data meant that repeated
use of spi_prepare and spi_freeplan would leak memory at the session level,
as per report from Christian Schröder. In addition, spi_prepare
leaked a lot of transient data within the current plperl function's SPI
Proc context, which would be a problem for repeated use of spi_prepare
within a single plperl function call; and it wasn't terribly careful
about releasing permanent allocations in event of an error, either.
In passing, clean up some copy-and-pasteos in query-lookup error messages.
Alex Hunsaker and Tom Lane
Diffstat (limited to 'src/tools/pginclude/cpluspluscheck')
0 files changed, 0 insertions, 0 deletions