fixed Japanese multi-byte detection