summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2009-11-25 11:20:41 -0800
committerBrion Vibber <brion@pobox.com>2009-11-25 11:23:11 -0800
commit6d5d63636a30654d92db5903972ccd6bf816a5cd (patch)
tree2fd03b455389dc3d86445aa5dd37f7d4a943608d /lib
parent3b2f39e1e17d4ae352be347dd8259e32fe430a84 (diff)
Drop error message on setlocale() failure; this is harmless, since we actually have a working locale set up.
Diffstat (limited to 'lib')
-rw-r--r--lib/util.php7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/util.php b/lib/util.php
index 5bf4f6091..6946f60fe 100644
--- a/lib/util.php
+++ b/lib/util.php
@@ -58,18 +58,17 @@ function common_init_language()
// (say, ga_ES for Galego/Galician) it seems to take it.
common_init_locale("en_US");
+ // Note that this setlocale() call may "fail" but this is harmless;
+ // gettext will still select the right language.
$language = common_language();
$locale_set = common_init_locale($language);
+
setlocale(LC_CTYPE, 'C');
// So we do not have to make people install the gettext locales
$path = common_config('site','locale_path');
bindtextdomain("statusnet", $path);
bind_textdomain_codeset("statusnet", "UTF-8");
textdomain("statusnet");
-
- if(!$locale_set) {
- common_log(LOG_INFO, 'Language requested:' . $language . ' - locale could not be set. Perhaps that system locale is not installed.', __FILE__);
- }
}
function common_timezone()