From 3f69cbb189a7f54d7f4389a2b8a71f0c23dfd04d Mon Sep 17 00:00:00 2001 From: Pierre Krieger Date: Thu, 7 Aug 2014 18:05:51 +0200 Subject: Fix two warnings on X11 --- src/x11/mod.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/x11/mod.rs b/src/x11/mod.rs index 4088f29..c9541b9 100644 --- a/src/x11/mod.rs +++ b/src/x11/mod.rs @@ -154,12 +154,12 @@ impl Window { // getting the pointer let fn_ptr = { - let mut addr = unsafe { ffi::glXGetProcAddress(b"glXCreateContextAttribs".as_ptr() - as *const u8) } as *const (); + let mut addr = ffi::glXGetProcAddress(b"glXCreateContextAttribs".as_ptr() + as *const u8) as *const (); if addr.is_null() { - addr = unsafe { ffi::glXGetProcAddress(b"glXCreateContextAttribsARB".as_ptr() - as *const u8) } as *const (); + addr = ffi::glXGetProcAddress(b"glXCreateContextAttribsARB".as_ptr() + as *const u8) as *const (); } addr.to_option().map(|addr| { -- cgit v1.2.3