diff options
author | Pierre Krieger <pierre.krieger1708@gmail.com> | 2015-02-18 08:58:37 +0100 |
---|---|---|
committer | Pierre Krieger <pierre.krieger1708@gmail.com> | 2015-02-18 09:00:00 +0100 |
commit | ba7f2a923f769af0d566da2397e7649f57c251f1 (patch) | |
tree | f4a90259d19b97501b11785067d3686e228b4597 /src/x11 | |
parent | eb330030de6d74c04b870f51351db0e67676f311 (diff) | |
download | glutin-ba7f2a923f769af0d566da2397e7649f57c251f1.tar.gz glutin-ba7f2a923f769af0d566da2397e7649f57c251f1.zip |
Don't call MakeCurrent(null, null) when destroying
Diffstat (limited to 'src/x11')
-rw-r--r-- | src/x11/window/mod.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/x11/window/mod.rs b/src/x11/window/mod.rs index 0c501ff..05fcf14 100644 --- a/src/x11/window/mod.rs +++ b/src/x11/window/mod.rs @@ -59,7 +59,8 @@ unsafe impl Sync for Window {} impl Drop for XWindow { fn drop(&mut self) { unsafe { - ffi::glx::MakeCurrent(self.display, 0, ptr::null()); + // we don't call MakeCurrent(0, 0) because we are not sure that the context + // is still the current one ffi::glx::DestroyContext(self.display, self.context); if self.is_fullscreen { |