Move hexpatch to Rust

This commit is contained in:
topjohnwu
2023-06-20 18:17:26 -07:00
parent 5805573625
commit 399b9e5eba
13 changed files with 78 additions and 39 deletions

View File

@ -26,6 +26,11 @@ pub mod ffi {
Debug,
}
unsafe extern "C++" {
include!("misc.hpp");
fn mut_u8_patch(buf: &mut [u8], from: &[u8], to: &[u8]) -> Vec<usize>;
}
extern "Rust" {
fn log_with_rs(level: LogLevel, msg: &[u8]);
fn exit_on_error(b: bool);