0 | module System.Linux.Pthreads.Prim
 1 |
 2 | import Data.C.Ptr
 3 | import System.Posix.Signal.Prim
 4 | import System.Posix.Pthreads.Prim
 5 |
 6 | %default total
 7 |
 8 | %foreign "C:li_pthread_sigqueue, posix-idris"
 9 | prim__pthread_sigqueue : AnyPtr -> Bits32 -> CInt -> PrimIO Bits32
10 |
11 | ||| Sends a realtime signal plus data word to a thread.
12 | |||
13 | ||| Note that `sig` must be in the range [SIGRTMIN, SIGRTMAX].
14 | export %inline
15 | pthreadSigqueue : PthreadT -> Signal -> (word : CInt) -> EPrim ()
16 | pthreadSigqueue p s word =
17 |   posToUnit $ prim__pthread_sigqueue p.ptr s.sig word
18 |