Re: BUG #17415: Unable to use underscore as first character in set_config custom parameter

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Japin Li <japinli(at)hotmail(dot)com>
Cc: danielpolski(at)gmail(dot)com, pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #17415: Unable to use underscore as first character in set_config custom parameter
Date: 2022-02-23 15:59:00
Message-ID: 1012792.1645631940@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Japin Li <japinli(at)hotmail(dot)com> writes:
> On Wed, 23 Feb 2022 at 16:36, PG Bug reporting form <noreply(at)postgresql(dot)org> wrote:
>> SELECT set_config('_foo.bar', 'foo', FALSE);
>> ERROR: invalid configuration parameter name "_foo.bar"
>> DETAIL: Custom parameter names must be two or more simple identifiers
>> separated by dots.

> According to the comment of valid_custom_variable_name(), the custom variable
> must be two or more identifiers separated dots, and the identifier confirm
> scan.l, see below:
> However, the code in valid_custom_variable_name() doesn't confirm it.

Yeah, it's supposed to match scan.l, so that's an embarrassing
oversight. Will apply patch.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2022-02-23 16:27:30 Re: BUG #17416: Server crashes due to python3 stack overflow on executing multiple plpy.rollback() calls
Previous Message Tomas Vondra 2022-02-23 15:41:22 Re: BUG #17406: Segmentation fault on GiST index after 14.2 upgrade