From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Ronan Dunklau <ronan(dot)dunklau(at)aiven(dot)io> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com> |
Subject: | Re: Converting contrib SQL functions to new style |
Date: | 2024-11-06 00:51:09 |
Message-ID: | Zyq9fXnmc5YiXik_@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, Nov 05, 2024 at 10:14:02AM +0100, Ronan Dunklau wrote:
> Sorry you're right I missed one for xml2. But most importantly I forgot to
> update the meson build files for every one of them, using only the Makefile...
If you want to catch that easily in the future, you can also set up
the CI within your own repo. This has saved me many times and the
cfbot sometimes takes a few days to report back. This usually reports
within 15 minutes.
I was wondering what was going on here, and this patch comes down to
switching all these definitions from that:
CREATE FUNCTION lo_oid(lo) RETURNS pg_catalog.oid AS
'SELECT $1::pg_catalog.oid' LANGUAGE SQL STRICT IMMUTABLE PARALLEL SAFE;
To that:
+CREATE OR REPLACE FUNCTION lo_oid(lo) RETURNS pg_catalog.oid
+LANGUAGE SQL STRICT IMMUTABLE PARALLEL SAFE
+RETURN (SELECT $1::pg_catalog.oid);
This makes the executions more robust run-time search_path checks. Is
that something that should be considered for a backpatch, actually?
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2024-11-06 00:52:21 | Re: define pg_structiszero(addr, s, r) |
Previous Message | David Rowley | 2024-11-06 00:38:50 | Re: define pg_structiszero(addr, s, r) |