Remove whitespaces before double colon in errors and logs
This commit is contained in:
@@ -224,7 +224,7 @@ public:
|
||||
{
|
||||
if (nReadPosNext > vch.size())
|
||||
{
|
||||
throw std::ios_base::failure("CDataStream::read() : end of data");
|
||||
throw std::ios_base::failure("CDataStream::read(): end of data");
|
||||
}
|
||||
memcpy(pch, &vch[nReadPos], nSize);
|
||||
nReadPos = 0;
|
||||
@@ -244,7 +244,7 @@ public:
|
||||
if (nReadPosNext >= vch.size())
|
||||
{
|
||||
if (nReadPosNext > vch.size())
|
||||
throw std::ios_base::failure("CDataStream::ignore() : end of data");
|
||||
throw std::ios_base::failure("CDataStream::ignore(): end of data");
|
||||
nReadPos = 0;
|
||||
vch.clear();
|
||||
return (*this);
|
||||
@@ -374,18 +374,18 @@ public:
|
||||
CAutoFile& read(char* pch, size_t nSize)
|
||||
{
|
||||
if (!file)
|
||||
throw std::ios_base::failure("CAutoFile::read : file handle is NULL");
|
||||
throw std::ios_base::failure("CAutoFile::read: file handle is NULL");
|
||||
if (fread(pch, 1, nSize, file) != nSize)
|
||||
throw std::ios_base::failure(feof(file) ? "CAutoFile::read : end of file" : "CAutoFile::read : fread failed");
|
||||
throw std::ios_base::failure(feof(file) ? "CAutoFile::read: end of file" : "CAutoFile::read: fread failed");
|
||||
return (*this);
|
||||
}
|
||||
|
||||
CAutoFile& write(const char* pch, size_t nSize)
|
||||
{
|
||||
if (!file)
|
||||
throw std::ios_base::failure("CAutoFile::write : file handle is NULL");
|
||||
throw std::ios_base::failure("CAutoFile::write: file handle is NULL");
|
||||
if (fwrite(pch, 1, nSize, file) != nSize)
|
||||
throw std::ios_base::failure("CAutoFile::write : write failed");
|
||||
throw std::ios_base::failure("CAutoFile::write: write failed");
|
||||
return (*this);
|
||||
}
|
||||
|
||||
@@ -401,7 +401,7 @@ public:
|
||||
{
|
||||
// Serialize to this stream
|
||||
if (!file)
|
||||
throw std::ios_base::failure("CAutoFile::operator<< : file handle is NULL");
|
||||
throw std::ios_base::failure("CAutoFile::operator<<: file handle is NULL");
|
||||
::Serialize(*this, obj, nType, nVersion);
|
||||
return (*this);
|
||||
}
|
||||
@@ -411,7 +411,7 @@ public:
|
||||
{
|
||||
// Unserialize from this stream
|
||||
if (!file)
|
||||
throw std::ios_base::failure("CAutoFile::operator>> : file handle is NULL");
|
||||
throw std::ios_base::failure("CAutoFile::operator>>: file handle is NULL");
|
||||
::Unserialize(*this, obj, nType, nVersion);
|
||||
return (*this);
|
||||
}
|
||||
@@ -452,7 +452,7 @@ protected:
|
||||
return false;
|
||||
size_t read = fread((void*)&vchBuf[pos], 1, readNow, src);
|
||||
if (read == 0) {
|
||||
throw std::ios_base::failure(feof(src) ? "CBufferedFile::Fill : end of file" : "CBufferedFile::Fill : fread failed");
|
||||
throw std::ios_base::failure(feof(src) ? "CBufferedFile::Fill: end of file" : "CBufferedFile::Fill: fread failed");
|
||||
} else {
|
||||
nSrcPos += read;
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user