initdb: emit message when using default ICU locale.
authorJeff Davis <[email protected]>
Tue, 28 Mar 2023 14:55:57 +0000 (07:55 -0700)
committerJeff Davis <[email protected]>
Tue, 28 Mar 2023 15:24:43 +0000 (08:24 -0700)
Helpful to determine from test logs whether the locale came from the
environment or a command-line option.

Discussion: https://postgr.es/m/04182066-7655-344a-b8b7-040b1b2490fb%40enterprisedb.com
Reviewed-by: Peter Eisentraut
src/bin/initdb/initdb.c

index 0acfd0fea299200f7476dff39db41fc1ff03a1a0..6b20a962eccb12111579225aac406d089a72573f 100644 (file)
@@ -2339,7 +2339,10 @@ setlocales(void)
    {
        /* acquire default locale from the environment, if not specified */
        if (icu_locale == NULL)
+       {
            icu_locale = default_icu_locale();
+           printf(_("Using default ICU locale \"%s\".\n"), icu_locale);
+       }
 
        /*
         * In supported builds, the ICU locale ID will be checked by the