Emre Hasegeli <[email protected]> writes:
>> + ReleaseCatCacheList(list);
>> + heap_close(pg_enum, RowExclusiveLock);
> Maybe we better release them before reporting error, too. I would
> release the list after the loop, close the heap before ereport().
Transaction abort will clean up such resources just fine; if it did
not, then any function you call would have problems if it threw an
error. I would not contort the logic to free stuff before ereport.
regards, tom lane
--
Sent via pgsql-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers