mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 11:28:03 +02:00
fix OctreeSceneStat unpacking in Application
This commit is contained in:
parent
a9d5723eb3
commit
9c57d1544f
1 changed files with 5 additions and 11 deletions
|
@ -3596,19 +3596,13 @@ int Application::processOctreeStats(NLPacket& packet, SharedNodePointer sendingN
|
||||||
int statsMessageLength = 0;
|
int statsMessageLength = 0;
|
||||||
|
|
||||||
const QUuid& nodeUUID = sendingNode->getUUID();
|
const QUuid& nodeUUID = sendingNode->getUUID();
|
||||||
OctreeSceneStats* octreeStats;
|
|
||||||
|
|
||||||
// now that we know the node ID, let's add these stats to the stats for that node...
|
// now that we know the node ID, let's add these stats to the stats for that node...
|
||||||
_octreeSceneStatsLock.lockForWrite();
|
_octreeSceneStatsLock.lockForWrite();
|
||||||
auto it = _octreeServerSceneStats.find(nodeUUID);
|
|
||||||
if (it != _octreeServerSceneStats.end()) {
|
OctreeSceneStats* octreeStats = &_octreeServerSceneStats[nodeUUID];
|
||||||
octreeStats = &it->second;
|
statsMessageLength = octreeStats->unpackFromPacket(packet);
|
||||||
statsMessageLength = octreeStats->unpackFromPacket(packet);
|
|
||||||
} else {
|
|
||||||
OctreeSceneStats temp;
|
|
||||||
statsMessageLength = temp.unpackFromPacket(packet);
|
|
||||||
octreeStats = &temp;
|
|
||||||
}
|
|
||||||
_octreeSceneStatsLock.unlock();
|
_octreeSceneStatsLock.unlock();
|
||||||
|
|
||||||
VoxelPositionSize rootDetails;
|
VoxelPositionSize rootDetails;
|
||||||
|
|
Loading…
Reference in a new issue