1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2025-01-19 04:52:12 +01:00

LP-277 silence OPMap log output

it is just too verbose...
This commit is contained in:
Philippe Renon 2016-04-03 23:30:04 +02:00
parent 3498f3c981
commit 1ceb6d7143
2 changed files with 10 additions and 1 deletions

View File

@ -181,18 +181,23 @@ QByteArray OPMaps::GetImageFrom(const MapType::Types &type, const Point &pos, co
default:
break;
}
#ifdef DEBUG_GMAPS
qDebug() << "Timeout is " << Timeout;
#endif // DEBUG_GMAPS
reply = network.get(qheader);
#ifdef DEBUG_GMAPS
qDebug() << "reply " << reply;
#endif // DEBUG_GMAPS
QTime time;
while ((!(reply->isFinished()) || (time.elapsed() > (6 * Timeout)))) {
QCoreApplication::processEvents(QEventLoop::AllEvents);
}
#ifdef DEBUG_GMAPS
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 ((reply->error() != QNetworkReply::NoError) | (time.elapsed() > Timeout * 6)) {
qDebug() << "reply error: " << reply->error() << " see table at - http://doc.qt.io/qt-5/qnetworkreply.html";
return ret;

View File

@ -86,7 +86,9 @@ void TileCacheQueue::run()
usleep(44);
delete task;
} else {
#ifdef DEBUG_TILECACHEQUEUE
qDebug() << "Cache engine BEGIN WAIT";
#endif // DEBUG_TILECACHEQUEUE
waitmutex.lock();
int tout = 4000;
if (!waitc.wait(&waitmutex, tout)) {
@ -101,7 +103,9 @@ void TileCacheQueue::run()
}
mutex.unlock();
}
#ifdef DEBUG_TILECACHEQUEUE
qDebug() << "Cache Engine DID NOT TimeOut";
#endif // DEBUG_TILECACHEQUEUE
waitmutex.unlock();
}
}