Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix compilation on arm using stable rust 1.5 #181

Merged
merged 2 commits into from
Jan 7, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/face.rs
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ impl<'a> Face<'a> {
None
} else {
let family_name = unsafe {
CStr::from_ptr(family_name).to_bytes().to_vec()
CStr::from_ptr(family_name as *const _).to_bytes().to_vec()
};
String::from_utf8(family_name).ok()
}
Expand All @@ -324,7 +324,7 @@ impl<'a> Face<'a> {
None
} else {
let style_name = unsafe {
CStr::from_ptr(style_name).to_bytes().to_vec()
CStr::from_ptr(style_name as *const _).to_bytes().to_vec()
};
String::from_utf8(style_name).ok()
}
Expand All @@ -349,7 +349,7 @@ impl<'a> Face<'a> {
None
} else {
let face_name = unsafe {
CStr::from_ptr(face_name).to_bytes().to_vec()
CStr::from_ptr(face_name as *const _).to_bytes().to_vec()
};
String::from_utf8(face_name).ok()
}
Expand Down
2 changes: 1 addition & 1 deletion src/library.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ impl Library {
.and_then(|s| CString::new(s).ok())
.ok_or(Error::InvalidPath));
let err = unsafe {
ffi::FT_New_Face(self.raw, path.as_ptr(), face_index as ffi::FT_Long, &mut face)
ffi::FT_New_Face(self.raw, path.as_ptr() as *const _, face_index as ffi::FT_Long, &mut face)
};
if err == ffi::FT_Err_Ok {
Ok(Face::from_raw(self.raw, face))
Expand Down