summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorMike Morris <michael.patrick.morris@gmail.com>2014-09-09 17:06:22 -0400
committerMike Morris <michael.patrick.morris@gmail.com>2014-09-09 17:06:22 -0400
commitc32bb852484420647502a58e880bf8251c13416a (patch)
tree649090d7941e47d772017843fd0d339945f1fb6e /common
parent74c4f976d1437e81e9bd57ee98fde05fba8c6e80 (diff)
parent2a50fccd24e762d0de5a53bac358e5ddfea8d213 (diff)
downloadqtlocation-mapboxgl-c32bb852484420647502a58e880bf8251c13416a.tar.gz
Merge branch 'master' into libuv010
Diffstat (limited to 'common')
-rw-r--r--common/headless_view.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/common/headless_view.cpp b/common/headless_view.cpp
index 3fb090f2b5..f790d90cec 100644
--- a/common/headless_view.cpp
+++ b/common/headless_view.cpp
@@ -151,6 +151,13 @@ HeadlessView::~HeadlessView() {
#if MBGL_USE_CGL
CGLDestroyContext(gl_context);
#endif
+
+#if MBGL_USE_GLX
+ glXMakeCurrent(x_display, None, NULL);
+ glXDestroyContext(x_display, gl_context);
+ XFree(x_info);
+ XCloseDisplay(x_display);
+#endif
}
void HeadlessView::notify_map_change(mbgl::MapChange /*change*/, mbgl::timestamp /*delay*/) {