diff options
author | Jim Meyering <jim@meyering.net> | 2001-03-06 18:11:01 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2001-03-06 18:11:01 +0000 |
commit | 218b44aa061a0f5ab71f2307720a702149b41035 (patch) | |
tree | f00f11ec809daeaa15fb1624566be80260cf7195 /lib/unicodeio.c | |
parent | 6cd8911583e2afeeaee6184a99fd484f0528ded5 (diff) | |
download | gnulib-218b44aa061a0f5ab71f2307720a702149b41035.tar.gz |
(print_unicode_char): Simplify accordingly.
Diffstat (limited to 'lib/unicodeio.c')
-rw-r--r-- | lib/unicodeio.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/unicodeio.c b/lib/unicodeio.c index 2771132d8e..9f90366439 100644 --- a/lib/unicodeio.c +++ b/lib/unicodeio.c @@ -1,6 +1,6 @@ /* Unicode character output to streams with locale dependent encoding. - Copyright (C) 2000 Free Software Foundation, Inc. + Copyright (C) 2000, 2001 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published @@ -124,13 +124,11 @@ print_unicode_char (FILE *stream, unsigned int code) extern const char *locale_charset PARAMS ((void)); const char *charset = locale_charset (); - is_utf8 = (charset != NULL && !strcmp (charset, UTF8_NAME)); + is_utf8 = !strcmp (charset, UTF8_NAME); #if HAVE_ICONV if (!is_utf8) { - utf8_to_local = (charset != NULL - ? iconv_open (charset, UTF8_NAME) - : (iconv_t)(-1)); + utf8_to_local = iconv_open (charset, UTF8_NAME); if (utf8_to_local == (iconv_t)(-1)) { /* For an unknown encoding, assume ASCII. */ |