Skip to content

Commit

Permalink
Adds kern_close for 11.00
Browse files Browse the repository at this point in the history
  • Loading branch information
ultimaweapon committed May 11, 2024
1 parent 5450916 commit 144c1b1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ps4k-1100/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,7 @@ impl ps4k::version::KernelVersion for KernelVersion {
flags: c_int,
mode: c_int,
) -> c_int;

#[offset(0x416920)]
unsafe fn kern_close(&self, td: *mut Self::Thread, fd: c_int) -> c_int;
}
4 changes: 4 additions & 0 deletions ps4k/src/version/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ pub trait KernelVersion: Send + Sync + 'static {
mode: c_int,
) -> c_int;

/// # Safety
/// `td` cannot be null.
unsafe fn kern_close(&self, td: *mut Self::Thread, fd: c_int) -> c_int;

/// # Safety
/// `base` must point to a valid address of the kernel. Behavior is undefined if format of the
/// kernel is unknown.
Expand Down

0 comments on commit 144c1b1

Please sign in to comment.