summaryrefslogtreecommitdiff
path: root/src/sys/signal.rs
diff options
context:
space:
mode:
authorBrian L. Troutwine <brian@troutwine.us>2021-12-27 15:37:30 -0800
committerBrian L. Troutwine <brian@troutwine.us>2021-12-30 20:40:48 -0800
commit77febe0e6b4e144992ea1b26ae1b9b45b746d970 (patch)
tree59e1a4ace5a4c9df7f4d110bac4595298f68ad6e /src/sys/signal.rs
parentb9eb19778a58603aae232bc838a8b8d8afd87c56 (diff)
downloadnix-77febe0e6b4e144992ea1b26ae1b9b45b746d970.zip
Introduce timer_* support
This commit adds support for the signal timer mechanism in POSIX, the mirror to timerfd on Linux. Resolves #1424 Signed-off-by: Brian L. Troutwine <brian@troutwine.us>
Diffstat (limited to 'src/sys/signal.rs')
-rw-r--r--src/sys/signal.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/sys/signal.rs b/src/sys/signal.rs
index b655604d..9750d890 100644
--- a/src/sys/signal.rs
+++ b/src/sys/signal.rs
@@ -1085,6 +1085,11 @@ mod sigevent {
pub fn sigevent(&self) -> libc::sigevent {
self.sigevent
}
+
+ /// Returns a mutable pointer to the `sigevent` wrapped by `self`
+ pub fn as_mut_ptr(&mut self) -> *mut libc::sigevent {
+ &mut self.sigevent
+ }
}
impl<'a> From<&'a libc::sigevent> for SigEvent {