diff options
author | Stefan Wildemann <stefan.wildemann@metalstrolche.de> | 2017-01-26 10:28:51 +0100 |
---|---|---|
committer | Stefan Wildemann <gta04@metalstrolche.de> | 2017-02-23 19:40:26 +0100 |
commit | 3f77629fdfe769e75c331d24c2db27c4f6c2a8b2 (patch) | |
tree | c84979fb793324da4c1b7c99592e56157ef27010 /navit/graphics | |
parent | 55b355180411f80618d8e2768b8810724e423518 (diff) | |
download | navit-3f77629fdfe769e75c331d24c2db27c4f6c2a8b2.tar.gz |
Fix: Qt5: clean up things even if there i no app object
Diffstat (limited to 'navit/graphics')
-rw-r--r-- | navit/graphics/qt5/graphics_qt5.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/navit/graphics/qt5/graphics_qt5.cpp b/navit/graphics/qt5/graphics_qt5.cpp index 87fc82b63..53f3dfcd6 100644 --- a/navit/graphics/qt5/graphics_qt5.cpp +++ b/navit/graphics/qt5/graphics_qt5.cpp @@ -91,9 +91,12 @@ graphics_destroy(struct graphics_priv *gr) /* destroy overlays hash */ g_hash_table_destroy(gr->overlays); /* destroy global application if destroying the last */ - if(gr->argc > 0 && navit_app != NULL) + if(gr->argc > 0) { - delete (navit_app); + if(navit_app != NULL) + { + delete (navit_app); + } navit_app = NULL; /* destroy argv if any */ while(gr->argc > 0) |