Special case C_COLLATION_OID in pg_newlocale_from_collation().
Jeff Davis <jdavis@postgresql.org>
Special case C_COLLATION_OID in pg_newlocale_from_collation(). Allow pg_newlocale_from_collation(C_COLLATION_OID) to work even if there's no catalog access, which some extensions expect. Not known to be a bug without extensions involved, but backport to 18. Also corrects an issue in master with dummy_c_locale (introduced in commit 5a38104b36) where deterministic was not set. That wasn't a bug, but could have been if that structure was used more widely. Reported-by: Alexander Kukushkin <cyberdemn@gmail.com> Reviewed-by: Alexander Kukushkin <cyberdemn@gmail.com> Discussion: https://postgr.es/m/CAFh8B=nj966ECv5vi_u3RYij12v0j-7NPZCXLYzNwOQp9AcPWQ@mail.gmail.com Backpatch-through: 18
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/regex/regc_pg_locale.c | modified | +5 −31 |
| src/backend/utils/adt/pg_locale.c | modified | +13 −0 |
Discussion
- tiny step toward threading: reduce dependence on setlocale() 33 messages · 2024-06-06 → 2025-10-28