Strip directions if it contains bad characters.