osfmk/man/mach_port_extract_member.html
Function - Extract the specified receive right from the specified port set.
**kern\_return\_t mach\_port\_extract\_member** **(ipc\_space\_t**_task_, **mach\_port\_name\_t** _member_, **mach\_port\_name\_t** set**);**
task[in task send right] The task holding the port set and receive right.member[in scalar] The task's name for the receive right.set[in scalar] The task's name for the port set.
The mach_port_extract_member function removes a receive right from a port set. Any other port set memberships for the receive right are not affected. A receive right can be a member of any number of portsets simultaneously.
This interface is machine word length specific because of the port name parameter.
KERN_INVALID_NAME member or set did not denote a right. KERN_INVALID_RIGHT member denoted a right, but not a receive right, or set denoted a right, but not a port set. KERN_NOT_IN_SET member was not in set.
Functions: mach_port_extract_member, mach_port_move_member, mach_port_get_set_status, mach_port_get_attributes.