mirror of
https://github.com/postgres/postgres.git
synced 2026-10-23 13:29:09 +03:00
Clearly define case mapping upper bounds that cover all providers, locales, and encodings: PG_MAX_CASEMAP_MBCHARS, PG_MAX_CASEMAP_EXPANSION, and PG_CASEMAP_BUFSZ. Also redefine UTF8_CASEMAP_BUFSZ to include room for a NUL for consistency with PG_CASEMAP_BUFSZ. Use PG_CASEMAP_BUFSZ for the static buffer in ltree/crc32.c. Remove macros UNICODE_CASEMAP_LEN (which was redundant with UNICODE_MAX_CASEMAP_CODEPOINTS from unicode_limits.h), and UNICODE_CASEMAP_BUFSZ which was not as descriptive or helpful. Suggested-by: Heikki Linnakangas <hlinnaka@iki.fi> Reviewed-by: Rithvika Devisetti <devisettirithvika@gmail.com> Discussion: https://postgr.es/m/2cfbc37ae8deccd3825e36b7f31c391cbf8ff9b8.camel@j-davis.com