aboutsummaryrefslogtreecommitdiff
path: root/src/main.rs
diff options
context:
space:
mode:
authorMatias Linares <matiaslina@gmail.com>2020-06-22 20:33:24 -0300
committerMatias Linares <matiaslina@gmail.com>2020-06-22 20:33:24 -0300
commit71e220b5f94c8af1ddfbc8e57182d9a51c1f6136 (patch)
tree2de62131f562224f4377a81961fc3c27bd28070e /src/main.rs
parent0763564eedc459a98e63a65f7ffee8ad37100fe7 (diff)
downloaddotwm-master.tar.gz
Use MaybeUninit::uninit() in favor of mem::uninitialized()HEADmaster
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main.rs b/src/main.rs
index fab737a..1f56bf2 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -18,7 +18,7 @@ pub mod socket;
pub mod desktop;
use std::collections::HashMap;
-use std::mem::uninitialized;
+use std::mem::MaybeUninit;
use std::fs;
use std::path::{PathBuf};
use std::io::{Read,Write};
@@ -106,7 +106,7 @@ fn main() {
Event::Drag(e) => {
// We can "compress" the drag notify here.
unsafe{
- let mut new_ev = uninitialized();
+ let mut new_ev = MaybeUninit::uninit().assume_init();
while xlib::XCheckTypedEvent(dotwm.display, xlib::MotionNotify, &mut new_ev) != 0 {};
};
exec_func(&mut dotwm, &mut bindings, 1, e.state, xlib::XEvent::from(e));