Browse Source

wchar: fix inverted parameters in error message

The error message should output "fromcode -> tocode" rather than
"tocode -> fromcode".  Seems to be a typo due to the order of the func
called:
iconv_t iconv_open(const char *tocode, const char *fromcode);

Signed-off-by: André Goddard Rosa <andre.goddard@gmail.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
André Goddard Rosa 15 years ago
parent
commit
6f49b76f5c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      libc/misc/wchar/wchar.c

+ 1 - 1
libc/misc/wchar/wchar.c

@@ -1679,7 +1679,7 @@ int main(int argc, char **argv)
 		goto USAGE;
 	}
 	if ((ic = iconv_open(opts[0],opts[1])) == ((iconv_t)(-1))) {
-		error_msg( "unsupported codeset in %s -> %s conversion\n", opts[0], opts[1]);
+		error_msg( "unsupported codeset in %s -> %s conversion\n", opts[1], opts[0]);
 	}
 	if (opts[3]) {				/* -c */
 		((_UC_iconv_t *) ic)->skip_invalid_input = 1;