summaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
authorKonstantin Käfer <mail@kkaefer.com>2014-02-17 17:55:47 +0100
committerKonstantin Käfer <mail@kkaefer.com>2014-02-17 17:55:47 +0100
commit9fb05741d65912611782676c08ff9bf7cc104861 (patch)
tree3b5a689c7b18007aca65fd7f2cc0c6431f1ac65d /linux
parent9d89bc090989f972ee5487c58df859d5ab4c348d (diff)
downloadqtlocation-mapboxgl-9fb05741d65912611782676c08ff9bf7cc104861.tar.gz
make sure that mapView is initialized before referencing into it
Diffstat (limited to 'linux')
-rw-r--r--linux/main.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/linux/main.cpp b/linux/main.cpp
index c51d27f824..1576a5be70 100644
--- a/linux/main.cpp
+++ b/linux/main.cpp
@@ -207,13 +207,15 @@ public:
llmr::Map map;
};
-MapView *mapView;
+MapView *mapView = nullptr;
namespace llmr {
namespace platform {
void restart(void *) {
- mapView->dirty = true;
+ if (mapView) {
+ mapView->dirty = true;
+ }
}