Finally fixed utf8/ascii output bug