Re: codlin_month is up and complain - PL/Python crash - Mailing list pgsql-hackers

From Tom Lane
Subject Re: codlin_month is up and complain - PL/Python crash
Date
Msg-id 26179.1266422736@sss.pgh.pa.us
Whole thread Raw
In response to codlin_month is up and complain - PL/Python crash  (Zdenek Kotala <Zdenek.Kotala@Sun.COM>)
Responses Re: codlin_month is up and complain - PL/Python crash
List pgsql-hackers
Zdenek Kotala <Zdenek.Kotala@Sun.COM> writes:
> I revived codlin_month and it falls during PL/Python test:
> http://www.pgbuildfarm.org/cgi-bin/show_log.pl?nm=codlin_moth&dt=2010-02-16%2015:09:05

All of the MemoryContextSwitchTo calls in plpython seem to be in
patterns like this:
   MemoryContext oldcontext;
   oldcontext = CurrentMemoryContext;   PG_TRY();   {       ... do something ...   }   PG_CATCH();   {
MemoryContextSwitchTo(oldcontext);

Since oldcontext is only set in the one place, it really shouldn't
require "volatile" decoration, but maybe it does.  Can you do some
testing to see if that would fix it?

(Of course, really plpython's bogus approach to error handling ought
to get thrown out and rewritten from scratch, but that's not happening
right now.)
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Listen / Notify - what to do when the queue is full
Next
From: Peter Eisentraut
Date:
Subject: Re: codlin_month is up and complain - PL/Python crash