mirror of
https://github.com/overte-org/overte.git
synced 2025-04-22 09:33:36 +02:00
fix octree server HTTPRequestHandler for url handling
This commit is contained in:
parent
f8279c1f5b
commit
40fa4bfbd2
2 changed files with 4 additions and 4 deletions
|
@ -236,7 +236,7 @@ void OctreeServer::initHTTPManager(int port) {
|
|||
_httpManager = new HTTPManager(port, documentRoot, this, this);
|
||||
}
|
||||
|
||||
bool OctreeServer::handleHTTPRequest(HTTPConnection* connection, const QString& path) {
|
||||
bool OctreeServer::handleHTTPRequest(HTTPConnection* connection, const QUrl& url) {
|
||||
|
||||
#ifdef FORCE_CRASH
|
||||
if (connection->requestOperation() == QNetworkAccessManager::GetOperation
|
||||
|
@ -259,9 +259,9 @@ bool OctreeServer::handleHTTPRequest(HTTPConnection* connection, const QString&
|
|||
bool showStats = false;
|
||||
|
||||
if (connection->requestOperation() == QNetworkAccessManager::GetOperation) {
|
||||
if (path == "/") {
|
||||
if (url.path() == "/") {
|
||||
showStats = true;
|
||||
} else if (path == "/resetStats") {
|
||||
} else if (url.path() == "/resetStats") {
|
||||
_octreeInboundPacketProcessor->resetStats();
|
||||
resetSendingStats();
|
||||
showStats = true;
|
||||
|
|
|
@ -97,7 +97,7 @@ public:
|
|||
static void trackPacketSendingTime(float time);
|
||||
static float getAveragePacketSendingTime() { return _averagePacketSendingTime.getAverage(); }
|
||||
|
||||
bool handleHTTPRequest(HTTPConnection* connection, const QString& path);
|
||||
bool handleHTTPRequest(HTTPConnection* connection, const QUrl& url);
|
||||
|
||||
virtual void aboutToFinish();
|
||||
|
||||
|
|
Loading…
Reference in a new issue