Fix print() handling of non-ASCII chars.