Re: BUG #15599: Segfault at MakeExpandedObjectReadOnlyInternal

From: Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org, exclusion(at)gmail(dot)com
Subject: Re: BUG #15599: Segfault at MakeExpandedObjectReadOnlyInternal
Date: 2019-01-19 10:20:05
Message-ID: 87pnstgde6.fsf@news-spur.riddles.org.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

>>>>> "PG" == PG Bug reporting form <noreply(at)postgresql(dot)org> writes:

PG> Bug reference: 15599
PG> Logged by: Alexander Lakhin
PG> Email address: exclusion(at)gmail(dot)com
PG> PostgreSQL version: 11.1
PG> Operating system: Ubuntu 18.04
PG> Description:

PG> The PostgreSQL server crashes with the following query (excerpt
PG> from regression test, run it after `make check`):

Not a bug.

PG> CREATE FUNCTION overpaid(emp)
PG> RETURNS hobbies_r
PG> AS '/src/postgres/src/test/regress/regress.so'
PG> LANGUAGE C STRICT;

"overpaid" in regress.so returns a boolean scalar, not a row of any
kind. It is the responsibility of the person issuing CREATE FUNCTION for
a C-language function to get the types right; if they are wrong, it can
(as you observed) crash the server, which is why this action is
restricted to database superusers.

--
Andrew (irc:RhodiumToad)

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Alexander Lakhin 2019-01-19 10:57:15 Re: BUG #15599: Segfault at MakeExpandedObjectReadOnlyInternal
Previous Message PG Bug reporting form 2019-01-19 08:58:13 BUG #15599: Segfault at MakeExpandedObjectReadOnlyInternal