mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-12-25 02:10:53 +00:00
Changed: Typo fixes (thanks to Vagrant!)
This commit is contained in:
parent
98606fb5b5
commit
39668984c1
4 changed files with 16 additions and 16 deletions
|
@ -1222,18 +1222,18 @@ void CFileContainer::addSearchBigFile (const string &sBigFilename, bool recurse,
|
||||||
//nlfseek64 (Handle, 0, SEEK_END);
|
//nlfseek64 (Handle, 0, SEEK_END);
|
||||||
//uint32 nFileSize = ftell (Handle);
|
//uint32 nFileSize = ftell (Handle);
|
||||||
nlfseek64 (Handle, nFileSize-4, SEEK_SET);
|
nlfseek64 (Handle, nFileSize-4, SEEK_SET);
|
||||||
uint32 nOffsetFromBegining;
|
uint32 nOffsetFromBeginning;
|
||||||
if (fread (&nOffsetFromBegining, sizeof(uint32), 1, Handle) != 1)
|
if (fread (&nOffsetFromBeginning, sizeof(uint32), 1, Handle) != 1)
|
||||||
{
|
{
|
||||||
fclose(Handle);
|
fclose(Handle);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef NL_BIG_ENDIAN
|
#ifdef NL_BIG_ENDIAN
|
||||||
NLMISC_BSWAP32(nOffsetFromBegining);
|
NLMISC_BSWAP32(nOffsetFromBeginning);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
nlfseek64 (Handle, nOffsetFromBegining, SEEK_SET);
|
nlfseek64 (Handle, nOffsetFromBeginning, SEEK_SET);
|
||||||
uint32 nNbFile;
|
uint32 nNbFile;
|
||||||
if (fread (&nNbFile, sizeof(uint32), 1, Handle) != 1)
|
if (fread (&nNbFile, sizeof(uint32), 1, Handle) != 1)
|
||||||
{
|
{
|
||||||
|
|
|
@ -148,18 +148,18 @@ struct BNPHeader
|
||||||
uint32 nFileSize=CFile::getFileSize (filename);
|
uint32 nFileSize=CFile::getFileSize (filename);
|
||||||
nlfseek64 (f, nFileSize-sizeof(uint32), SEEK_SET);
|
nlfseek64 (f, nFileSize-sizeof(uint32), SEEK_SET);
|
||||||
|
|
||||||
uint32 nOffsetFromBegining;
|
uint32 nOffsetFromBeginning;
|
||||||
if (fread (&nOffsetFromBegining, sizeof(uint32), 1, f) != 1)
|
if (fread (&nOffsetFromBeginning, sizeof(uint32), 1, f) != 1)
|
||||||
{
|
{
|
||||||
fclose (f);
|
fclose (f);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef NL_BIG_ENDIAN
|
#ifdef NL_BIG_ENDIAN
|
||||||
NLMISC_BSWAP32(nOffsetFromBegining);
|
NLMISC_BSWAP32(nOffsetFromBeginning);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (nlfseek64 (f, nOffsetFromBegining, SEEK_SET) != 0)
|
if (nlfseek64 (f, nOffsetFromBeginning, SEEK_SET) != 0)
|
||||||
{
|
{
|
||||||
fclose (f);
|
fclose (f);
|
||||||
return false;
|
return false;
|
||||||
|
|
|
@ -1701,18 +1701,18 @@ bool CPatchManager::readBNPHeader(const string &SourceName, vector<SBNPFile> &Fi
|
||||||
uint32 nFileSize = NLMISC::CFile::getFileSize (SourceName);
|
uint32 nFileSize = NLMISC::CFile::getFileSize (SourceName);
|
||||||
nlfseek64 (f, nFileSize-sizeof(uint32), SEEK_SET);
|
nlfseek64 (f, nFileSize-sizeof(uint32), SEEK_SET);
|
||||||
|
|
||||||
uint32 nOffsetFromBegining;
|
uint32 nOffsetFromBeginning;
|
||||||
if (fread (&nOffsetFromBegining, sizeof(uint32), 1, f) != 1)
|
if (fread (&nOffsetFromBeginning, sizeof(uint32), 1, f) != 1)
|
||||||
{
|
{
|
||||||
fclose(f);
|
fclose(f);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef NL_BIG_ENDIAN
|
#ifdef NL_BIG_ENDIAN
|
||||||
NLMISC_BSWAP32(nOffsetFromBegining);
|
NLMISC_BSWAP32(nOffsetFromBeginning);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (nlfseek64 (f, nOffsetFromBegining, SEEK_SET) != 0)
|
if (nlfseek64 (f, nOffsetFromBeginning, SEEK_SET) != 0)
|
||||||
{
|
{
|
||||||
fclose(f);
|
fclose(f);
|
||||||
return false;
|
return false;
|
||||||
|
|
|
@ -150,18 +150,18 @@ static void markBNPFile(std::string &path)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32 nOffsetFromBegining;
|
uint32 nOffsetFromBeginning;
|
||||||
if (fread (&nOffsetFromBegining, sizeof(uint32), 1, f) != 1)
|
if (fread (&nOffsetFromBeginning, sizeof(uint32), 1, f) != 1)
|
||||||
{
|
{
|
||||||
fclose (f);
|
fclose (f);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef NL_BIG_ENDIAN
|
#ifdef NL_BIG_ENDIAN
|
||||||
NLMISC_BSWAP32(nOffsetFromBegining);
|
NLMISC_BSWAP32(nOffsetFromBeginning);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (nlfseek64 (f, nOffsetFromBegining, SEEK_SET) != 0)
|
if (nlfseek64 (f, nOffsetFromBeginning, SEEK_SET) != 0)
|
||||||
{
|
{
|
||||||
fclose (f);
|
fclose (f);
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue