[glib/glib-2-48] gio-querymodules: Call setlocale in main function
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib/glib-2-48] gio-querymodules: Call setlocale in main function
- Date: Wed, 17 Aug 2016 21:40:02 +0000 (UTC)
commit 2d74f09587c9262f1606f356c8ced19aaee1527b
Author: Ting-Wei Lan <lantw src gnome org>
Date: Mon Jan 11 13:51:32 2016 +0800
gio-querymodules: Call setlocale in main function
It is required to correctly show translated messages on some locales.
https://bugzilla.gnome.org/show_bug.cgi?id=760423
gio/gio-querymodules.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/gio/gio-querymodules.c b/gio/gio-querymodules.c
index 8dc2421..30c9c88 100644
--- a/gio/gio-querymodules.c
+++ b/gio/gio-querymodules.c
@@ -23,6 +23,7 @@
#include <gstdio.h>
#include <errno.h>
+#include <locale.h>
static gboolean
is_valid_module_name (const gchar *basename)
@@ -134,6 +135,8 @@ main (gint argc,
return 1;
}
+ setlocale (LC_ALL, "");
+
/* Be defensive and ensure we're linked to GObject */
g_type_ensure (G_TYPE_OBJECT);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]