On Friday 30 April 2010 20:09:48 Tom Lane wrote:
> Andres Freund <andres(at)anarazel(dot)de> writes:
> > On Friday 30 April 2010 19:39:32 Tom Lane wrote:
> >> Yeah. There's a leak of the tuptable in the CATCH path, too. Will fix.
> > Yes, theres even more than that (measured it) in the error case. Will
> > have a look later today.
> Here's the patch I'm planning to apply --- working it back into the
> back branches now.
The one I measured was 9.0 only:
diff --git a/src/pl/plpython/plpython.c b/src/pl/plpython/plpython.c
index 6063628..a6dd9d0 100644
*** 538,546 ****
--- 538,548 ----
PLy_curr_procedure = proc;
PLy_curr_procedure = save_curr_proc;
Found by running something like:
while true; do echo 'DO LANGUAGE plpythonu $$import
gc;gc.collect();plpy.execute("SELECT unknown"); $$;';done|psql -h /tmp -p 5433
The gc stuff is just to make real leaks way much easier to spot.
In response to
pgsql-bugs by date
|Next:||From: Andres Freund||Date: 2010-04-30 21:57:04|
|Subject: Re: plpython memory leak uppon empty resultsets in all versions|
|Previous:||From: Tom Lane||Date: 2010-04-30 18:09:48|
|Subject: Re: plpython memory leak uppon empty resultsets in all versions |