summaryrefslogtreecommitdiff
path: root/src/mbgl/tile
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2016-09-14 12:34:57 -0700
committerJohn Firebaugh <john.firebaugh@gmail.com>2016-09-14 13:41:56 -0700
commita9f5224664905ac28a372be6aad429a31790df03 (patch)
tree08d5ff56508e9683918371f7c08251e7e7e5272a /src/mbgl/tile
parentc8217a873940264387a7d8101f968798ac7d543e (diff)
downloadqtlocation-mapboxgl-a9f5224664905ac28a372be6aad429a31790df03.tar.gz
[core] Avoid gratuitous SymbolBucket creation
Diffstat (limited to 'src/mbgl/tile')
-rw-r--r--src/mbgl/tile/tile_worker.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mbgl/tile/tile_worker.cpp b/src/mbgl/tile/tile_worker.cpp
index 572f9054cd..97e682d697 100644
--- a/src/mbgl/tile/tile_worker.cpp
+++ b/src/mbgl/tile/tile_worker.cpp
@@ -167,9 +167,9 @@ TilePlacementResult TileWorker::redoPlacement(const PlacementConfig& config) {
for (auto& symbolLayout : symbolLayouts) {
symbolLayout->state = SymbolLayout::Placed;
- std::unique_ptr<Bucket> bucket = symbolLayout->place(*result.collisionTile);
- if (bucket->hasData() || symbolLayout->hasSymbolInstances()) {
- result.buckets.emplace(symbolLayout->bucketName, std::move(bucket));
+ if (symbolLayout->hasSymbolInstances()) {
+ result.buckets.emplace(symbolLayout->bucketName,
+ symbolLayout->place(*result.collisionTile));
}
}