pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Ted Yu <yuzhihong@gmail.com>
Cc: Andrew Dunstan <andrew@dunslane.net>
Cc: Amul Sul <sulamul@gmail.com>
Cc: Andres Freund <andres@anarazel.de>
Cc: Alexander Korotkov <aekorotkov@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: David G. Johnston <david.g.johnston@gmail.com>
Cc: Corey Huinker <corey.huinker@gmail.com>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Joe Conway <mail@joeconway.com>
Cc: Nikita Glukhov <n.gluhov@postgrespro.ru>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Subject: Re: Error-safe user functions
Date: Fri, 23 Dec 2022 16:22:47 -0500
Message-ID: <2791143.1671830567@sss.pgh.pa.us> (raw)
In-Reply-To: <CALte62wLvzOAigC5bdsxX73WGGi5zX5OiYmjkNYcRFkHo8nMYQ@mail.gmail.com>
References: <4009543.1670422833@sss.pgh.pa.us>
	<20221208215836.3naznqmal2m32hzc@awork3.anarazel.de>
	<512551.1670540229@sss.pgh.pa.us>
	<20221209023351.l362yejerfoq3lfp@awork3.anarazel.de>
	<633426.1670554790@sss.pgh.pa.us>
	<01ff2051-806d-af2f-4f9e-793f7ba9a3f8@dunslane.net>
	<778369.1670598993@sss.pgh.pa.us>
	<5aaf7c66-9df9-21a9-1ff4-02c7848def52@dunslane.net>
	<3bac9841-fe07-713d-fa42-606c225567d6@dunslane.net>
	<1436686.1670701118@sss.pgh.pa.us>
	<2b1e7d56-6f37-bad9-9702-053ab55ecf60@dunslane.net>
	<1805344.1670779451@sss.pgh.pa.us>
	<b54e97be-7316-2cab-6969-bfac6ec88ca6@dunslane.net>
	<1863335.1670783397@sss.pgh.pa.us>
	<CAAJ_b97KeDWUdpTKGOaFYPv0OicjOu6EW+QYWj-Ywrgj_aEy1g@mail.gmail.com>
	<2687377.1671033604@sss.pgh.pa.us>
	<2966981.1671057469@sss.pgh.pa.us>
	<1964968.1671727440@sss.pgh.pa.us>
	<9c8f22f2-7a37-fc4d-8e9f-3431c0d09c5a@dunslane.net>
	<CALte62wLvzOAigC5bdsxX73WGGi5zX5OiYmjkNYcRFkHo8nMYQ@mail.gmail.com>

Ted Yu <yuzhihong@gmail.com> writes:
> In makeItemLikeRegex :

> +                       /* See regexp.c for explanation */
> +                       CHECK_FOR_INTERRUPTS();
> +                       pg_regerror(re_result, &re_tmp, errMsg,
> sizeof(errMsg));
> +                       ereturn(escontext, false,

> Since an error is returned, I wonder if the `CHECK_FOR_INTERRUPTS` call is
> still necessary.

Yes, it is.  We don't want a query-cancel transformed into a soft error.

			regards, tom lane





view thread (175+ messages)  latest in thread

Message-ID: <2791143.1671830567@sss.pgh.pa.us>
Permalink:  ../2791143.1671830567@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/2791143.1671830567@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, yuzhihong@gmail.com, andrew@dunslane.net, sulamul@gmail.com, andres@anarazel.de, aekorotkov@gmail.com, robertmhaas@gmail.com, david.g.johnston@gmail.com, corey.huinker@gmail.com, alvherre@alvh.no-ip.org, mail@joeconway.com, n.gluhov@postgrespro.ru, pgsql-hackers@lists.postgresql.org
  Subject: Re: Error-safe user functions
  In-Reply-To: <2791143.1671830567@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox