Re: Crash on SRF execution

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Itai <itaid(at)outlook(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Crash on SRF execution
Date: 2015-03-15 15:49:44
Message-ID: 25884.1426434584@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Itai <itaid(at)outlook(dot)com> writes:
> I'm attempting to program a simple SRF function but it constantly crashes (details and code below).
> Any idea why?

Looks like you're pallocing some stuff in the calling context (ie, a
short-lived context) during the first execution and expecting it to
still be there in later executions. You'd need to allocate those
data structures in the multi_call_memory_ctx instead.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2015-03-15 15:50:27 Re: Crash on SRF execution
Previous Message Itai 2015-03-15 15:40:11 Crash on SRF execution