mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-31 16:52:10 +01:00
LP-277 silence OPMap log output
it is just too verbose...
This commit is contained in:
parent
3498f3c981
commit
1ceb6d7143
@ -181,18 +181,23 @@ QByteArray OPMaps::GetImageFrom(const MapType::Types &type, const Point &pos, co
|
|||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
#ifdef DEBUG_GMAPS
|
||||||
qDebug() << "Timeout is " << Timeout;
|
qDebug() << "Timeout is " << Timeout;
|
||||||
|
#endif // DEBUG_GMAPS
|
||||||
reply = network.get(qheader);
|
reply = network.get(qheader);
|
||||||
|
#ifdef DEBUG_GMAPS
|
||||||
qDebug() << "reply " << reply;
|
qDebug() << "reply " << reply;
|
||||||
|
#endif // DEBUG_GMAPS
|
||||||
|
|
||||||
QTime time;
|
QTime time;
|
||||||
while ((!(reply->isFinished()) || (time.elapsed() > (6 * Timeout)))) {
|
while ((!(reply->isFinished()) || (time.elapsed() > (6 * Timeout)))) {
|
||||||
QCoreApplication::processEvents(QEventLoop::AllEvents);
|
QCoreApplication::processEvents(QEventLoop::AllEvents);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef DEBUG_GMAPS
|
||||||
qDebug() << "Finished?" << reply->error() << " abort?" << (time.elapsed() > Timeout * 6);
|
qDebug() << "Finished?" << reply->error() << " abort?" << (time.elapsed() > Timeout * 6);
|
||||||
|
#endif // DEBUG_GMAPS
|
||||||
// If you are seeing Error 6 here you are dealing with a QT SSL Bug!!!
|
// If you are seeing Error 6 here you are dealing with a QT SSL Bug!!!
|
||||||
|
|
||||||
if ((reply->error() != QNetworkReply::NoError) | (time.elapsed() > Timeout * 6)) {
|
if ((reply->error() != QNetworkReply::NoError) | (time.elapsed() > Timeout * 6)) {
|
||||||
qDebug() << "reply error: " << reply->error() << " see table at - http://doc.qt.io/qt-5/qnetworkreply.html";
|
qDebug() << "reply error: " << reply->error() << " see table at - http://doc.qt.io/qt-5/qnetworkreply.html";
|
||||||
return ret;
|
return ret;
|
||||||
|
@ -86,7 +86,9 @@ void TileCacheQueue::run()
|
|||||||
usleep(44);
|
usleep(44);
|
||||||
delete task;
|
delete task;
|
||||||
} else {
|
} else {
|
||||||
|
#ifdef DEBUG_TILECACHEQUEUE
|
||||||
qDebug() << "Cache engine BEGIN WAIT";
|
qDebug() << "Cache engine BEGIN WAIT";
|
||||||
|
#endif // DEBUG_TILECACHEQUEUE
|
||||||
waitmutex.lock();
|
waitmutex.lock();
|
||||||
int tout = 4000;
|
int tout = 4000;
|
||||||
if (!waitc.wait(&waitmutex, tout)) {
|
if (!waitc.wait(&waitmutex, tout)) {
|
||||||
@ -101,7 +103,9 @@ void TileCacheQueue::run()
|
|||||||
}
|
}
|
||||||
mutex.unlock();
|
mutex.unlock();
|
||||||
}
|
}
|
||||||
|
#ifdef DEBUG_TILECACHEQUEUE
|
||||||
qDebug() << "Cache Engine DID NOT TimeOut";
|
qDebug() << "Cache Engine DID NOT TimeOut";
|
||||||
|
#endif // DEBUG_TILECACHEQUEUE
|
||||||
waitmutex.unlock();
|
waitmutex.unlock();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user