diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2007-05-12 09:35:07 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2007-05-12 09:35:07 +0200 |
commit | df463b5a2a6814b12922dd7b2acad88263979c02 (patch) | |
tree | 6e5168eac32d6d9eec9903a7388595d91ee67d9c /vdr.c | |
parent | d472e8b63bdc4e3674e25c8e6dff3902c9255f8f (diff) | |
download | vdr-df463b5a2a6814b12922dd7b2acad88263979c02.tar.gz vdr-df463b5a2a6814b12922dd7b2acad88263979c02.tar.bz2 |
Fixed getting the code setting from the locale
Diffstat (limited to 'vdr.c')
-rw-r--r-- | vdr.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -22,7 +22,7 @@ * * The project's page is at http://www.cadsoft.de/vdr * - * $Id: vdr.c 1.289 2007/04/30 09:52:51 kls Exp $ + * $Id: vdr.c 1.290 2007/05/12 09:35:07 kls Exp $ */ #include <getopt.h> @@ -493,7 +493,9 @@ int main(int argc, char *argv[]) // Set the system character table: - char *LangEnv = getenv("LANG"); + char *LangEnv = setlocale(LC_CTYPE, ""); + if (!LangEnv) + LangEnv = getenv("LANG"); // last resort in case locale stuff isn't installed if (LangEnv) { char *CodeSet = strchr(LangEnv, '.'); if (CodeSet) { |