Re: Remaining dependency on setlocale()

From: Jeff Davis <pgsql(at)j-davis(dot)com>
To: Peter Eisentraut <peter(at)eisentraut(dot)org>, Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com>
Cc: Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Remaining dependency on setlocale()
Date: 2026-01-27 19:44:36
Message-ID: cf976b924de917c762b53e0d7bcb5ded2d0b1aa3.camel@j-davis.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, 2026-01-06 at 14:20 -0800, Jeff Davis wrote:
> Looks good to me.

I closed the entry for this commitfest, though there are a few loose
ends:

* Not sure what to do about strerror & gettext. One idea is to wrap
both in a uselocale() everywhere. For windows, we use the special
setlocale() mode. For NetBSD, I don't know if we can or should do
anything -- maybe just prevent changing lc_messages?

* pg_strcasecmp() still used many places in the backend. We should
consider replacing with an ASCII variant or one that uses the database
collation.

* A number of places still rely on isalpha(), etc., for simple
parsing (e.g. ltree).

Regards,
Jeff Davis

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Masahiko Sawada 2026-01-27 20:04:46 Re: pg_upgrade: optimize replication slot caught-up check
Previous Message Masahiko Sawada 2026-01-27 19:43:53 Re: RepOrigin vs. replorigin