Itai <itaid@outlook.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