fix reading strings in io