fix bug 3172: open file in binary mode, otherwise iteration of a binary file with for_each stops early.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21211 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Bernhard Roider 2007-10-25 22:36:59 +00:00
parent 4ca3a3d59c
commit 74d22c2ce4

View File

@ -148,7 +148,7 @@ unsigned long sum(FileName const & file)
return 0;
string filename = file.toFilesystemEncoding();
ifstream ifs(filename.c_str());
ifstream ifs(filename.c_str(), std::ios_base::in | std::ios_base::binary);
if (!ifs)
return 0;