On 11/7/06, Tom Lane <[EMAIL PROTECTED]> wrote:
"Brendan Jurd" <[EMAIL PROTECTED]> writes: > Is it crucial that result sets be cleared before going out of scope?It sounds like it'd leak memory inside psql; but realistically that's probably not an enormous problem for this usage. How much uglification of the code are we talking about to fix it?
Should be just six extra lines (patch attached, untested). This isn't really an uglification of the code, so much as bringing this particular code segment into line with the existing ugliness standard of the rest of the function. =) It certainly isn't pretty. It's been a long time since I looked down the barrel of a 'goto'. This sort of thing feels like it should be dealt with by RAII or try/catch, but this is C we're talking about. It's hard to do things gracefully. Regards, BJ
describe.c.diff
Description: Binary data
---------------------------(end of broadcast)--------------------------- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate