use pg_strncasecmp to replace strncmp when compare "pg_"

Started by tanghy.fnst@fujitsu.comover 5 years ago4 messageshackers
Beta feature

Hackorum builds and tests every patch posted to the lists, not only commitfest submissions. This is Hackorum's own CI rather than the PostgreSQL project's, and it is still under testing - please report anything that looks wrong.

won't retrysuccessCI history

You can run a PostgreSQL built from this patch straight from Docker, with no checkout and no build:

docker run --rm -p 5432:5432 ghcr.io/hackorum-dev/postgres-patch:t44094
psql -h localhost -U postgres

Built from patchset v1 (message #1), July 27, 2026 at 05:07 PM.

Every patchset is also pushed to a branch of our PostgreSQL fork, so you can check out the same tree CI built. Without a PostgreSQL checkout:

git clone --branch t44094_1 https://github.com/hackorum-dev/postgres.git

In a checkout you already have, add the fork once:

git remote add hackorum https://github.com/hackorum-dev/postgres.git

then, for this patchset and every later one:

git fetch hackorum t44094_1 && git checkout t44094_1

Patchset v1 (message #1) is on t44094_1

Jump to latest
#1tanghy.fnst@fujitsu.com
tanghy.fnst@fujitsu.com

Attachments:

t44094_1
0001-use-pg_strncasecmp-to-replace-strncmp-when-compare-p.patchapplication/octet-stream; name=0001-use-pg_strncasecmp-to-replace-strncmp-when-compare-p.patchDownload+2-3
#2Kyotaro Horiguchi
horikyota.ntt@gmail.com
In reply to: tanghy.fnst@fujitsu.com (#1)
Re: use pg_strncasecmp to replace strncmp when compare "pg_"

At Thu, 22 Apr 2021 12:44:28 +0000, "tanghy.fnst@fujitsu.com" <tanghy.fnst@fujitsu.com> wrote in

Hi

When try to improve the tab compleation feature in [1], I found an existing problem and a typo.
The patch was attached, please kindly to take a look at it. Thanks.

[1]
htdrop indetps://www.postgresql.org/message-id/OS0PR01MB61131A4347D385F02F60E123FB469%40OS0PR01MB6113.jpnprd01.prod.outlook.com

That doesn't matter at all for now since we match schema identifiers
case-sensitively. Maybe it should be a part of the patch in [1].

regards.

--
Kyotaro Horiguchi
NTT Open Source Software Center

#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Kyotaro Horiguchi (#2)
Re: use pg_strncasecmp to replace strncmp when compare "pg_"

Kyotaro Horiguchi <horikyota.ntt@gmail.com> writes:

At Thu, 22 Apr 2021 12:44:28 +0000, "tanghy.fnst@fujitsu.com" <tanghy.fnst@fujitsu.com> wrote in

When try to improve the tab compleation feature in [1], I found an existing problem and a typo.
The patch was attached, please kindly to take a look at it. Thanks.

That doesn't matter at all for now since we match schema identifiers
case-sensitively. Maybe it should be a part of the patch in [1].

Yeah --- maybe this'd make sense as part of a full patch to improve
tab-complete.c's handling of case folding, but I'm suspicious that
applying it on its own would just make things less consistent.

regards, tom lane

#4tanghy.fnst@fujitsu.com
tanghy.fnst@fujitsu.com
In reply to: Tom Lane (#3)
RE: use pg_strncasecmp to replace strncmp when compare "pg_"

On Friday, April 23, 2021 2:06 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote

Kyotaro Horiguchi <horikyota.ntt@gmail.com> writes:
That doesn't matter at all for now since we match schema identifiers
case-sensitively. Maybe it should be a part of the patch in [1].

Yeah --- maybe this'd make sense as part of a full patch to improve
tab-complete.c's handling of case folding, but I'm suspicious that
applying it on its own would just make things less consistent.

Thanks for your reply. Merged this patch to [1]/messages/by-id/OS0PR01MB6113CA04E06D5BF221BC4FE2FB429@OS0PR01MB6113.jpnprd01.prod.outlook.com. Any further comment on [1]/messages/by-id/OS0PR01MB6113CA04E06D5BF221BC4FE2FB429@OS0PR01MB6113.jpnprd01.prod.outlook.com is very welcome.

[1]: /messages/by-id/OS0PR01MB6113CA04E06D5BF221BC4FE2FB429@OS0PR01MB6113.jpnprd01.prod.outlook.com

Regards,
Tang