Use coercion on types failing compilation on 64 bit raspbian bullseye (#292)

Awesome! Thanks

Closes #291
This commit is contained in:
Matt Thompson 2022-04-16 09:27:35 -07:00 committed by GitHub
parent a4f7958fab
commit 7019ba41ea
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View file

@ -1089,7 +1089,7 @@ impl Window {
let ctx = xkbcommon_sys::xkb_context_new(0);
let kb_map_ptr = xkbcommon_sys::xkb_keymap_new_from_string(
ctx,
addr as *const i8,
addr as _,
xkbcommon_sys::xkb_keymap_format::XKB_KEYMAP_FORMAT_TEXT_V1,
0,
);

View file

@ -397,7 +397,7 @@ impl Window {
);
let empty_string = b"\0";
(d.lib.XSetLocaleModifiers)(empty_string.as_ptr() as *const i8);
(d.lib.XSetLocaleModifiers)(empty_string.as_ptr() as _);
let xim = (d.lib.XOpenIM)(
d.display,
@ -614,8 +614,8 @@ impl Window {
#[inline]
pub fn set_icon(&mut self, icon: Icon) {
// XChangeProperty
let net_string_ptr = b"_NET_WM_ICON\0".as_ptr() as *const i8;
let cardinal_ptr = b"CARDINAL\0".as_ptr() as *const i8;
let net_string_ptr = b"_NET_WM_ICON\0".as_ptr() as _;
let cardinal_ptr = b"CARDINAL\0".as_ptr() as _;
unsafe {
if let Icon::Buffer(ptr, len) = icon {