fix(minibsod): allow dump_registers and write_crash for Android x86_64 (#1577)

This commit is contained in:
Abc Xyz 2023-09-30 00:10:15 +03:00 committed by GitHub
parent 5b0e3dd3bc
commit 6f67919622
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -12,7 +12,10 @@ use libc::siginfo_t;
use crate::os::unix_signals::{ucontext_t, Signal}; use crate::os::unix_signals::{ucontext_t, Signal};
/// Write the content of all important registers /// Write the content of all important registers
#[cfg(all(target_os = "linux", target_arch = "x86_64"))] #[cfg(all(
any(target_os = "linux", target_os = "android"),
target_arch = "x86_64"
))]
#[allow(clippy::similar_names)] #[allow(clippy::similar_names)]
pub fn dump_registers<W: Write>( pub fn dump_registers<W: Write>(
writer: &mut BufWriter<W>, writer: &mut BufWriter<W>,
@ -414,7 +417,10 @@ fn dump_registers<W: Write>(
Ok(()) Ok(())
} }
#[cfg(all(target_os = "linux", target_arch = "x86_64"))] #[cfg(all(
any(target_os = "linux", target_os = "android"),
target_arch = "x86_64"
))]
fn write_crash<W: Write>( fn write_crash<W: Write>(
writer: &mut BufWriter<W>, writer: &mut BufWriter<W>,
signal: Signal, signal: Signal,