diff options
Diffstat (limited to 'support.c')
-rw-r--r-- | support.c | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -137,18 +137,17 @@ charset_init(void) } #endif -#ifdef HAVE_LANGINFO_CODESET /* get charset */ if( (charset=nl_langinfo(CODESET)) == NULL ) { fprintf(stderr, "nl_langinfo() failed using default:" DEFAULT_CHARSET "\n"); + charset = DEFAULT_CHARSET; } +#ifdef DEBUG + fprintf(stderr, "charset: %s\n", charset); #endif - if( charset==NULL ) - charset = DEFAULT_CHARSET; - #ifdef HAVE_ICONV /* allocate descriptor for character set conversion */ iconv_from_uft8 = iconv_open(charset, "UTF-8"); |