Page 1 of 1

passing a semaphore over mach msg

PostPosted: Tue Jun 06, 2017 9:30 am
by Robin191
Hello :)
I am new to the forum and would love some help about this topic.
i am trying to pass a semaphore object between the thread that created it in one process to a thread in a different process
using mach messages and keep using the semaphore from both sides for synchronization.
i understand that a semaphore is actually a port by itself but i don't really know how is it implemented, which rights does it have and so on.
i stumbled upon the fact that semaphores may be converted to and from ports and that would be great but can i do it in user mode ?
any directions on how to do this would be great !
i have no problem passing the semaphore number, but i can not use it...

thanks !