1use core::ffi::c_void;
2
3#[repr(C)]
4#[derive(Debug, Clone, Copy)]
5pub struct Patch {
6 pub addr: u32,
7 pub size: u32,
8 pub patch_bytes: *const c_void,
9 pub original_bytes: *const c_void,
10 pub enabled: bool,
11}
12
13unsafe extern "C" {
14 pub fn forge_patch_create(address: u32, bytes: *const c_void, length: u32, enable: bool) -> Patch;
15 pub fn forge_patch_destroy(patch: *mut Patch);
16
17 pub fn forge_patch_enable(patch: *mut Patch);
18 pub fn forge_patch_disable(patch: *mut Patch);
19}