fix parsing of escape chars