- some logging changes for helping test world synch better
This commit is contained in:
parent
c6c9478bca
commit
e5a62f57ef
|
@ -235,8 +235,8 @@ void LogFileThread::addLogEntry(SystemFlags::DebugType type, string logEntry) {
|
||||||
bool LogFileThread::checkSaveCurrentLogBufferToDisk() {
|
bool LogFileThread::checkSaveCurrentLogBufferToDisk() {
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
if(difftime(time(NULL),lastSaveToDisk) >= 5 ||
|
if(difftime(time(NULL),lastSaveToDisk) >= 5 ||
|
||||||
//LogFileThread::getLogEntryBufferCount() >= 2000000) {
|
LogFileThread::getLogEntryBufferCount() >= 1000000) {
|
||||||
LogFileThread::getLogEntryBufferCount() >= 10000) {
|
//LogFileThread::getLogEntryBufferCount() >= 10000) {
|
||||||
lastSaveToDisk = time(NULL);
|
lastSaveToDisk = time(NULL);
|
||||||
ret = true;
|
ret = true;
|
||||||
}
|
}
|
||||||
|
@ -258,7 +258,8 @@ void LogFileThread::execute() {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
for(;this->getQuitStatus() == false;) {
|
for(;this->getQuitStatus() == false;) {
|
||||||
if(checkSaveCurrentLogBufferToDisk() == true) {
|
while(this->getQuitStatus() == false &&
|
||||||
|
checkSaveCurrentLogBufferToDisk() == true) {
|
||||||
saveToDisk(false,false);
|
saveToDisk(false,false);
|
||||||
}
|
}
|
||||||
if(this->getQuitStatus() == false) {
|
if(this->getQuitStatus() == false) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user