mirror of
https://github.com/zebrajr/postgres.git
synced 2026-01-15 12:15:21 +00:00
Change some callers to use pg_ascii_toupper().
The input is ASCII anyway, so it's better to be clear that it's not locale-dependent. Discussion: https://postgr.es/m/450ceb6260cad30d7afdf155d991a9caafee7c0d.camel@j-davis.com
This commit is contained in:
@@ -479,7 +479,7 @@ pg_split_walfile_name(PG_FUNCTION_ARGS)
|
||||
|
||||
/* Capitalize WAL file name. */
|
||||
for (p = fname_upper; *p; p++)
|
||||
*p = pg_toupper((unsigned char) *p);
|
||||
*p = pg_ascii_toupper((unsigned char) *p);
|
||||
|
||||
if (!IsXLogFileName(fname_upper))
|
||||
ereport(ERROR,
|
||||
|
||||
@@ -1035,7 +1035,7 @@ cash_words(PG_FUNCTION_ARGS)
|
||||
appendStringInfoString(&buf, m0 == 1 ? " cent" : " cents");
|
||||
|
||||
/* capitalize output */
|
||||
buf.data[0] = pg_toupper((unsigned char) buf.data[0]);
|
||||
buf.data[0] = pg_ascii_toupper((unsigned char) buf.data[0]);
|
||||
|
||||
/* return as text datum */
|
||||
res = cstring_to_text_with_len(buf.data, buf.len);
|
||||
|
||||
Reference in New Issue
Block a user