SPI_Free() causes backend to close.

From: "Rod Taylor" <rod(dot)taylor(at)inquent(dot)com>
To: "Hackers List" <pgsql-hackers(at)postgresql(dot)org>
Subject: SPI_Free() causes backend to close.
Date: 2001-02-16 21:08:09
Message-ID: 017301c0985c$911f3a90$2205010a@jester
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Perhaps someone can explain what's wrong with this. Excuse the mess,
it was cut out of a much larger function but reliably creates the
error on my Postgres 7.1 beta 4 machine.

Compile C function, restart postgres (for the heck of it), create a
new db (I used 'stuff), import sql. The insert it runs at the end
fails, and:

pqReadData() -- backend closed the channel unexpectedly.....

Quite confused, if I remove the SPI_Finish() it works fine, but
complains every time an SPI_Connect is issued after the first run of
the function.

As you can see, the closure is SPI_Finish as the notice before
appears, and the notice after doesn't.

--
Rod Taylor

There are always four sides to every story: your side, their side, the
truth, and what really happened.

Attachment Content-Type Size
Taylor, Rod B.vcf text/x-vcard 451 bytes
bad_function.sql application/octet-stream 1.0 KB
bad_function.c application/octet-stream 2.2 KB

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2001-02-16 21:17:46 Re: beta5 ...
Previous Message Ned Lilly 2001-02-16 20:47:48 Re: Postgres Benchmark