]> git.lyx.org Git - features.git/commitdiff
Fix bug that files with nonascii filenames are always reported
authorEnrico Forestieri <forenr@lyx.org>
Wed, 14 Nov 2007 23:30:13 +0000 (23:30 +0000)
committerEnrico Forestieri <forenr@lyx.org>
Wed, 14 Nov 2007 23:30:13 +0000 (23:30 +0000)
as externally modified.

* src/Buffer.cpp (Buffer::readFile): filenames are always stored
as UTF-8 in the FileName class.

* src/support/FileName.h: correct comment.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21620 a592a061-630c-0410-9148-cb99ea01b6c8

src/Buffer.cpp
src/support/FileName.h

index 580e1023b6338400052f7f60bd7cbf4c1e44450c..9817c47e5bdf33763f2651cf9c32572afe4fbb7f 100644 (file)
@@ -762,7 +762,7 @@ Buffer::ReadStatus Buffer::readFile(Lexer & lex, FileName const & filename,
                // Save the timestamp and checksum of disk file. If filename is an
                // emergency file, save the timestamp and sum of the original lyx file
                // because isExternallyModified will check for this file. (BUG4193)
-               string diskfile = filename.toFilesystemEncoding();
+               string diskfile = filename.absFilename();
                if (suffixIs(diskfile, ".emergency"))
                        diskfile = diskfile.substr(0, diskfile.size() - 10);
                saveCheckSum(FileName(diskfile));
index a2b1c3c48d6fe3b7ca19cfd611109dab28fb063b..80db2ed35a735587d8312b9bcf546ab3895ed65a 100644 (file)
@@ -113,9 +113,7 @@ public:
 
 
 protected:
-       /// The absolute file name.
-       /// The encoding is currently unspecified, anything else than ASCII
-       /// may or may not work.
+       /// The absolute file name in UTF-8 encoding.
        std::string name_;
 };