Skip to content

Commit

Permalink
Fix warning
Browse files Browse the repository at this point in the history
  • Loading branch information
wyatt-herkamp committed Feb 1, 2024
1 parent 951e3fb commit 962841b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions winit/src/system.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ pub fn fetch_information<Message>(
pub(crate) fn information(
graphics_info: compositor::Information,
) -> Information {
use sysinfo::System;
use sysinfo::{Process, System};
let mut system = System::new_all();
system.refresh_all();

let cpu = system.global_cpu_info();

let memory_used = sysinfo::get_current_pid()
.and_then(|pid| system.process(pid).ok_or("Process not found"))
.map(|v| v.memory())
.map(Process::memory)
.ok();

Information {
Expand Down

0 comments on commit 962841b

Please sign in to comment.