git-svn-id: svn://db.shs.com.ru/pip@812 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5

This commit is contained in:
2019-06-25 12:12:45 +00:00
parent 6c7c81559c
commit 95fd35f9a7
2 changed files with 12 additions and 5 deletions

View File

@@ -487,13 +487,13 @@ void PIBinaryLog::parseLog(PIFile * f, PIBinaryLog::BinLogInfo * info, PIVector<
PIByteArray ba;
BinLogRecord br;
bool first = true;
llong hdr_size = sizeof(BinLogRecord) - sizeof(PIByteArray);
size_t hdr_size = sizeof(BinLogRecord) - sizeof(PIByteArray);
ba.resize(hdr_size);
while (1) {
ba.resize(hdr_size);
{
PIMutexLocker _ml(file_mutex);
if (f->read(ba.data(), ba.size_s()) > 0) {
if (f->read(ba.data(), ba.size()) > 0) {
ba >> br.id >> br.size >> br.timestamp;
} else
break;