[ros-diffs] [royce] 13996: don't end a string if the last character outputted was an escape, will cause output file to be invalid