summaryrefslogtreecommitdiff
path: root/include/mbgl/storage
diff options
context:
space:
mode:
authorIvo van Dongen <info@ivovandongen.nl>2017-05-26 17:49:33 +0300
committerIvo van Dongen <ivovandongen@users.noreply.github.com>2017-05-27 10:05:36 +0300
commit89129379f18b913a7c2b7a7ff99644e277e9d3ff (patch)
tree452a8e041ae69a6a6c2c1480ed47d51b7efb3e63 /include/mbgl/storage
parentb353f45fed45846a213d2f2b60a6936295b17c87 (diff)
downloadqtlocation-mapboxgl-89129379f18b913a7c2b7a7ff99644e277e9d3ff.tar.gz
[core] default file source - ensure thread safety for local file and asset requests
Diffstat (limited to 'include/mbgl/storage')
-rw-r--r--include/mbgl/storage/default_file_source.hpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/mbgl/storage/default_file_source.hpp b/include/mbgl/storage/default_file_source.hpp
index f612a01aac..1e60d2bc5a 100644
--- a/include/mbgl/storage/default_file_source.hpp
+++ b/include/mbgl/storage/default_file_source.hpp
@@ -140,9 +140,9 @@ public:
class Impl;
private:
+ // Shared so destruction is done on this thread
+ const std::shared_ptr<FileSource> assetFileSource;
const std::unique_ptr<util::Thread<Impl>> thread;
- const std::unique_ptr<FileSource> assetFileSource;
- const std::unique_ptr<FileSource> localFileSource;
std::string cachedBaseURL = mbgl::util::API_BASE_URL;
std::string cachedAccessToken;
};