format.df: fixed new bug in handling special characters