diff --git a/src/tools/uchardet.cpp b/src/tools/uchardet.cpp index d353a92..add141c 100644 --- a/src/tools/uchardet.cpp +++ b/src/tools/uchardet.cpp @@ -72,9 +72,15 @@ void detect(FILE *fp, printf("\n"); for (i = 0; i < candidates; i++) { - printf("\t%s (%f)\n", - uchardet_get_encoding(handle, i), - uchardet_get_confidence(handle, i)); + if (uchardet_get_language(handle, i)) + printf("\t%s / %s (%f)\n", + uchardet_get_encoding(handle, i), + uchardet_get_language(handle, i), + uchardet_get_confidence(handle, i)); + else + printf("\t%s (%f)\n", + uchardet_get_encoding(handle, i), + uchardet_get_confidence(handle, i)); } } else