]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/controllers/tex_helpers.C
more unicode filenames
[lyx.git] / src / frontends / controllers / tex_helpers.C
index 888a83e6e4d6176fd5659029d2f5e8bb69200bcc..fbc78c2d78b1e023b9e8e120072aa9084662b282 100644 (file)
@@ -103,9 +103,11 @@ void getTexFileList(string const & filename, std::vector<string> & list)
 
 string const getListOfOptions(string const & classname, string const & type)
 {
-       string const filename = getTexFileFromList(classname,type);
+       FileName const filename(getTexFileFromList(classname, type));
+       if (filename.empty())
+               return string();
        string optionList = string();
-       std::ifstream is(filename.c_str());
+       std::ifstream is(filename.toFilesystemEncoding().c_str());
        while (is) {
                string s;
                is >> s;