Re: [HACKERS] Refactoring identifier checks to consistently use strcmp - Mailing list pgsql-hackers

From Daniel Gustafsson
Subject Re: [HACKERS] Refactoring identifier checks to consistently use strcmp
Date
Msg-id 1EA22A7C-1EC1-451F-AB30-FEEF302FDBD4@yesql.se
Whole thread Raw
In response to Re: [HACKERS] Refactoring identifier checks to consistently use strcmp  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: [HACKERS] Refactoring identifier checks to consistently use strcmp
List pgsql-hackers
> On 26 Jan 2018, at 22:32, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
> Michael Paquier <michael.paquier@gmail.com> writes:
>> On Wed, Jan 24, 2018 at 09:47:50AM +0100, Daniel Gustafsson wrote:
>>> Attached is a rebased v7 patch which has your amendments (minus
>>> propname) which passes make check without errors.
>
>> Confirmed. I am switching the status as ready for committer for
>> volatility-v7.patch then.
>
> Poking through this,

Thanks!

> I notice that there are two reloptions-related
> "pg_strncasecmp" calls that did not get converted to "strncmp":
> reloptions.c:804

The way I read transformRelOptions(), oldOptions is not guaranteed to come from
the parser (though in reality it probably will be).  The namespace isn’t either
but passing an uppercase namespace should never be valid AFAICT, hence the
patch changing it to case sensitive comparison.

> and reloptions.h:169.

Oversight, completely missed that one.

cheers ./daniel

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [HACKERS] Refactoring identifier checks to consistently use strcmp
Next
From: "Rady, Doug"
Date:
Subject: Re: PATCH: pgbench - option to build using ppoll() for largerconnection counts