Changed: #878 Fix typos in comments/code

This commit is contained in:
kervala 2011-02-09 14:42:30 +01:00
parent 6881ee0ec2
commit e9023e9a49
2 changed files with 8 additions and 12 deletions

View file

@ -551,14 +551,13 @@ bool CInterfaceParser::parseInterface (const std::vector<std::string> & strings,
firstFileName = *it; firstFileName = *it;
string filename = CPath::lookup(firstFileName); string filename = CPath::lookup(firstFileName);
bool isInData = false; bool isInData = false;
if (filename.find ("@") != string::npos) string::size_type pos = filename.find ("@");
if (pos != string::npos)
{ {
vector<string> bigFilePaths; std::string bigFilename = CBigFile::getInstance().getBigFileName(filename.substr(0, pos));
CBigFile::getInstance().getBigFilePaths(bigFilePaths); std::string path = "data/"+filename.substr(0, pos);
if (CBigFile::getInstance().getBigFileName(filename.substr(0, filename.find ("@"))) != "data/"+filename.substr(0, filename.find ("@")))
isInData = false; isInData = bigFilename.find(path) != std::string::npos;
else
isInData = true;
} }
if ((needCheck && !isInData) || !file.open (CPath::lookup(firstFileName))) if ((needCheck && !isInData) || !file.open (CPath::lookup(firstFileName)))
@ -654,10 +653,7 @@ bool CInterfaceParser::parseInterface (const std::vector<std::string> & strings,
if (saveParseResult) if (saveParseResult)
{ {
nlassert(isFilename); nlassert(isFilename);
std::string outputFilename = std::string("data/") + CFile::getFilename(nextFileName) + std::string("_compressed"); std::string outputFilename = CPath::standardizePath("data") + CFile::getFilename(nextFileName) + std::string("_compressed");
#ifdef NL_OS_WINDOWS
outputFilename = CPath::standardizeDosPath(outputFilename);
#endif
COFile f; COFile f;
f.open(outputFilename); f.open(outputFilename);
f.serialCheck(UI_CACHE_SERIAL_CHECK); f.serialCheck(UI_CACHE_SERIAL_CHECK);