Improved handling of unicode files with non ascii characters. refs #1017