Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/search
diff options
context:
space:
mode:
authortatiana-yan <tatiana.kondakova@gmail.com>2018-07-19 17:04:13 +0300
committerVlad Mihaylenko <vxmihaylenko@gmail.com>2018-07-20 14:51:41 +0300
commit401f76559903845e9e0423d4b9187b2227c75119 (patch)
treee083e4bec974f743432f4acdd14c135c455e4515 /search
parent00aad3618e40180fd2ed32d5e4167a5fa50fc8f7 (diff)
[search] Fix possible crash
Diffstat (limited to 'search')
-rw-r--r--search/utils.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/search/utils.cpp b/search/utils.cpp
index cca289d5f9..ff8d2d0587 100644
--- a/search/utils.cpp
+++ b/search/utils.cpp
@@ -7,6 +7,8 @@
#include "indexer/data_source.hpp"
+#include "base/cancellable.hpp"
+
#include <cctype>
#include <utility>
@@ -96,8 +98,9 @@ void ForEachOfTypesInRect(DataSource const & dataSource, vector<uint32_t> const
vector<shared_ptr<MwmInfo>> infos;
dataSource.GetMwmsInfo(infos);
- CategoriesCache cache(types, {} /* cancellable */);
- auto pivotRectsCache = PivotRectsCache(1 /* maxNumEntries */, {} /* cancellable */,
+ base::Cancellable const cancellable;
+ CategoriesCache cache(types, cancellable);
+ auto pivotRectsCache = PivotRectsCache(1 /* maxNumEntries */, cancellable,
max(pivot.SizeX(), pivot.SizeY()) /* maxRadiusMeters */);
for (auto const & info : infos)