From 935e5a36a2bf0109c0366ff86b2636e633cda25d Mon Sep 17 00:00:00 2001 From: Akos Kiss Date: Tue, 20 Jan 2015 17:09:13 +0000 Subject: `c_char` isn't always `i8` --- src/x11/headless.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/x11/headless.rs') diff --git a/src/x11/headless.rs b/src/x11/headless.rs index 7692832..20d86e3 100644 --- a/src/x11/headless.rs +++ b/src/x11/headless.rs @@ -5,7 +5,7 @@ use libc; use std::{mem, ptr}; use super::ffi; -fn with_c_str(s: &str, f: F) -> T where F: FnOnce(*const i8) -> T { +fn with_c_str(s: &str, f: F) -> T where F: FnOnce(*const libc::c_char) -> T { use std::ffi::CString; let c_str = CString::from_slice(s.as_bytes()); f(c_str.as_slice_with_nul().as_ptr()) -- cgit v1.2.3