Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit253504f

Browse files
committed
Fix build of ICU support in Windows
and also any platform that does not have locale_t but enabled ICU.Author: Ashutosh Sharma <ashu.coek88@gmail.com>
1 parentbf6e4c3 commit253504f

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

‎src/backend/commands/collationcmds.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,10 +411,10 @@ get_icu_locale_comment(const char *localename)
411411
Datum
412412
pg_import_system_collations(PG_FUNCTION_ARGS)
413413
{
414-
#if defined(HAVE_LOCALE_T)&& !defined(WIN32)
415414
boolif_not_exists=PG_GETARG_BOOL(0);
416415
Oidnspid=PG_GETARG_OID(1);
417416

417+
#if defined(HAVE_LOCALE_T)&& !defined(WIN32)
418418
FILE*locale_a_handle;
419419
charlocalebuf[NAMEDATALEN];/* we assume ASCII so this is fine */
420420
intcount=0;
@@ -431,6 +431,12 @@ pg_import_system_collations(PG_FUNCTION_ARGS)
431431
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
432432
(errmsg("must be superuser to import system collations"))));
433433

434+
#if !(defined(HAVE_LOCALE_T)&& !defined(WIN32))&& !defined(USE_ICU)
435+
/* silence compiler warnings */
436+
(void)if_not_exists;
437+
(void)nspid;
438+
#endif
439+
434440
#if defined(HAVE_LOCALE_T)&& !defined(WIN32)
435441
locale_a_handle=OpenPipeStream("locale -a","r");
436442
if (locale_a_handle==NULL)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp