aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/dbsize.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2013-07-20 12:44:37 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2013-07-20 12:44:37 -0400
commitb3b10c39038c20457ef058c7f4e5589c28a84f1c (patch)
treef9a3c7627594eb57f08b8a8b8e125f0dfa2b59b4 /src/backend/utils/adt/dbsize.c
parentff41a5de0995f01a98b6fbc3a0c774b9a53e609a (diff)
downloadpostgresql-b3b10c39038c20457ef058c7f4e5589c28a84f1c.tar.gz
postgresql-b3b10c39038c20457ef058c7f4e5589c28a84f1c.zip
Fix error handling in PLy_spi_execute_fetch_result().
If an error is thrown out of the datatype I/O functions called by this function, we need to do subtransaction cleanup, which the previous coding entirely failed to do. Fortunately, both existing callers of this function already have proper cleanup logic, so re-throwing the exception is enough. Also, postpone creation of the resultset tupdesc until after the I/O conversions are complete, so that we won't leak memory in TopMemoryContext when such an error happens.
Diffstat (limited to 'src/backend/utils/adt/dbsize.c')
0 files changed, 0 insertions, 0 deletions