Minor changes

Former-commit-id: fd74c48a546663f4d4802826ee2d396b0874e2c9
This commit is contained in:
Lynix
2015-01-03 21:45:37 +01:00
parent 57b90112fb
commit 2bfb798dd9
6 changed files with 7 additions and 8 deletions

View File

@@ -733,7 +733,7 @@ bool NzFile::FillHash(NzAbstractHash* hash) const
unsigned int size;
while (remainingSize > 0)
{
size = (remainingSize >= NAZARA_CORE_FILE_BUFFERSIZE) ? NAZARA_CORE_FILE_BUFFERSIZE : static_cast<unsigned int>(remainingSize);
size = std::min(remainingSize, static_cast<nzUInt64>(NAZARA_CORE_FILE_BUFFERSIZE));
if (file.Read(&buffer[0], sizeof(char), size) != sizeof(char)*size)
{
NazaraError("Unable to read file");