- LYXERR(Debug::LYXVC) << "Checking if file is under rcs: "
- << tmp << endl;
- if (fs::is_readable(tmp.toFilesystemEncoding())) {
- LYXERR(Debug::LYXVC) << "Yes " << file
- << " is under rcs." << endl;
+ LYXERR(Debug::LYXVC, "Checking if file is under rcs: " << tmp);
+ if (tmp.isReadableFile()) {
+ LYXERR(Debug::LYXVC, "Yes " << file << " is under rcs.");
+ return tmp;
+ }
+
+ // Check if RCS/*,v exists.
+ tmp = FileName(addName(addPath(onlyPath(file.absFilename()), "RCS"), file.absFilename()) + ",v");
+ LYXERR(Debug::LYXVC, "Checking if file is under rcs: " << tmp);
+ if (tmp.isReadableFile()) {
+ LYXERR(Debug::LYXVC, "Yes " << file << " it is under rcs.");