From f932d5c7b57ff863adaa8b8eb27794dfe2ccc9f9 Mon Sep 17 00:00:00 2001 From: Val Packett Date: Mon, 3 Apr 2023 00:21:12 -0300 Subject: [PATCH] aix: add siginfo_t accessors for symmetry with other platforms --- src/unix/aix/powerpc64.rs | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/src/unix/aix/powerpc64.rs b/src/unix/aix/powerpc64.rs index 1f96ae37ad850..6c6b87db74893 100644 --- a/src/unix/aix/powerpc64.rs +++ b/src/unix/aix/powerpc64.rs @@ -192,6 +192,29 @@ s_no_extra_traits! { } } +impl siginfo_t { + pub unsafe fn si_addr(&self) -> *mut ::c_void { + self.si_addr + } + + #[cfg(libc_union)] + pub unsafe fn si_value(&self) -> ::sigval { + self.si_value + } + + pub unsafe fn si_pid(&self) -> ::pid_t { + self.si_pid + } + + pub unsafe fn si_uid(&self) -> ::uid_t { + self.si_uid + } + + pub unsafe fn si_status(&self) -> ::c_int { + self.si_status + } +} + cfg_if! { if #[cfg(feature = "extra_traits")] { #[cfg(libc_union)]