diff --git a/src/python_process_info.rs b/src/python_process_info.rs index f36bfb1f..528ff982 100644 --- a/src/python_process_info.rs +++ b/src/python_process_info.rs @@ -10,7 +10,9 @@ use std::slice; use anyhow::{Context, Error, Result}; use lazy_static::lazy_static; use proc_maps::{get_process_maps, MapRange}; -use remoteprocess::{Pid, ProcessMemory}; +#[cfg(not(target_os = "macos"))] +use remoteprocess::Pid; +use remoteprocess::ProcessMemory; use crate::binary_parser::{parse_binary, BinaryInfo}; use crate::config::Config; @@ -599,7 +601,7 @@ pub trait ContainsAddr { impl ContainsAddr for Vec { #[cfg(windows)] - fn contains_addr(&self, addr: usize) -> bool { + fn contains_addr(&self, _addr: usize) -> bool { // On windows, we can't just check if a pointer is valid by looking to see if it points // to something in the virtual memory map. Brute-force it instead true diff --git a/src/python_spy.rs b/src/python_spy.rs index fe1d0811..2b2a6fec 100644 --- a/src/python_spy.rs +++ b/src/python_spy.rs @@ -1,5 +1,3 @@ -#[cfg(windows)] -use regex::RegexBuilder; use std::collections::HashMap; #[cfg(all(target_os = "linux", feature = "unwind"))] use std::collections::HashSet;