diff options
author | Tor Lillqvist <tml@iki.fi> | 2013-01-06 12:41:07 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@iki.fi> | 2013-01-06 16:13:16 +0200 |
commit | bf850f6799e505e6d1735540e68e01c6b18ef22f (patch) | |
tree | bbbcf42855e8383772204e2649b76fa17b4fe087 /sal/osl | |
parent | More hacking on iOS stuff (diff) | |
download | core-bf850f6799e505e6d1735540e68e01c6b18ef22f.tar.gz core-bf850f6799e505e6d1735540e68e01c6b18ef22f.zip |
Streamline a bit for Android
Change-Id: I8233f6409d75bff23738e121efcdbd340035da9d
Diffstat (limited to 'sal/osl')
-rw-r--r-- | sal/osl/unx/nlsupport.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/sal/osl/unx/nlsupport.c b/sal/osl/unx/nlsupport.c index fd0e02466b64..b0f231f5c539 100644 --- a/sal/osl/unx/nlsupport.c +++ b/sal/osl/unx/nlsupport.c @@ -907,6 +907,12 @@ void _imp_getProcessLocale( rtl_Locale ** ppLocale ) void _imp_getProcessLocale( rtl_Locale ** ppLocale ) { +#ifdef ANDROID + /* No locale environment variables on Android, so why even bother + * with getenv(). + */ + locale = "en-US.UTF-8"; +#else /* simulate behavior off setlocale */ char * locale = getenv( "LC_ALL" ); @@ -917,13 +923,10 @@ void _imp_getProcessLocale( rtl_Locale ** ppLocale ) locale = getenv( "LANG" ); if( NULL == locale ) -#ifdef ANDROID - locale = "en-US.UTF-8"; -#else locale = "C"; -#endif *ppLocale = _parse_locale( locale ); +#endif } #endif |