summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorKonstantin Käfer <mail@kkaefer.com>2015-02-13 10:54:36 -0800
committerKonstantin Käfer <mail@kkaefer.com>2015-02-13 13:28:40 -0800
commitaecef6da1a7903ef318e02f62d1cdd97a2e3e53b (patch)
treeb64f944169db25800f6f09de8227cb98564bf65f /include
parent5d2ed0326ed27f32c4a8ec5e95ec9fc57139c7ec (diff)
downloadqtlocation-mapboxgl-aecef6da1a7903ef318e02f62d1cdd97a2e3e53b.tar.gz
make sure that the async handle always gets closed
Diffstat (limited to 'include')
-rw-r--r--include/mbgl/storage/default/request.hpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/mbgl/storage/default/request.hpp b/include/mbgl/storage/default/request.hpp
index 81ed14a568..e26d59e2d9 100644
--- a/include/mbgl/storage/default/request.hpp
+++ b/include/mbgl/storage/default/request.hpp
@@ -22,7 +22,6 @@ class Request : private util::noncopyable {
public:
using Callback = std::function<void(const Response &)>;
Request(const Resource &resource, uv_loop_t *loop, Callback callback);
- ~Request();
public:
// May be called from any thread.
@@ -33,6 +32,8 @@ public:
void cancel();
private:
+ ~Request();
+ void invoke();
static void notifyCallback(uv_async_t *async);
static void cancelCallback(uv_async_t *async);