summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Hacohen <tom@stosb.com>2015-11-17 12:07:39 +0000
committerTom Hacohen <tom@stosb.com>2015-11-17 12:07:42 +0000
commit8fcf9a0fe6e4dc3942cb42ec3c0f28d63d6cf694 (patch)
tree0a54973a3dbf348f7922de1b080e4d600c9fdcac
parentf1cffd77096c4314598629e12a4c42498ba2e7cf (diff)
Evas language: Fix language from locale function.
This function was trying to infer from the LANG env var, though it should have just queried the locale all along, as the language we want is the system's text language, and not necessarily the LANG variable's value. @fix.
-rw-r--r--src/lib/evas/common/language/evas_language_utils.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/evas/common/language/evas_language_utils.c b/src/lib/evas/common/language/evas_language_utils.c
index c9efc3b31b..7d13965cc9 100644
--- a/src/lib/evas/common/language/evas_language_utils.c
+++ b/src/lib/evas/common/language/evas_language_utils.c
@@ -21,6 +21,7 @@
21#endif 21#endif
22 22
23#include <stdlib.h> 23#include <stdlib.h>
24#include <locale.h>
24 25
25#include <Eina.h> 26#include <Eina.h>
26 27
@@ -134,7 +135,7 @@ evas_common_language_from_locale_get(void)
134 if (*lang) return lang; 135 if (*lang) return lang;
135 136
136 const char *locale; 137 const char *locale;
137 locale = getenv("LANG"); 138 locale = setlocale(LC_MESSAGES, NULL);
138 if (locale && *locale) 139 if (locale && *locale)
139 { 140 {
140 char *itr; 141 char *itr;