diff options
-rw-r--r-- | platform/darwin/src/MGLMapSnapshotter.mm | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/platform/darwin/src/MGLMapSnapshotter.mm b/platform/darwin/src/MGLMapSnapshotter.mm index 68bae4cd52..6449a7fd4f 100644 --- a/platform/darwin/src/MGLMapSnapshotter.mm +++ b/platform/darwin/src/MGLMapSnapshotter.mm @@ -146,10 +146,10 @@ const CGFloat MGLSnapshotterMinimumPixelSize = 64; }); dispatch_async(queue, ^{ - if (!weakSelf) { + __typeof__(self) strongSelf = weakSelf; + if (!strongSelf) { return; } - __typeof__(self) strongSelf = weakSelf; strongSelf->_mbglMapSnapshotter->snapshot(strongSelf->_snapshotCallback->self()); }); } |