| Previous | Next |
| MACH_RCV_IN_PROGRESS | MACH_RCV_TIMED_OUT |
MACH_RCV_INVALID_NAME
A receive-right and membership problem
MACH_RCV_INVALID_NAME means the receive_name passed to mach_msg does not identify a valid receive target in the caller’s namespace. Receiving is not permitted merely because a task knows a port’s numeric name: only the task holding the receive right can dequeue messages from that port. A port set is also distinct from an individual port, and membership rules affect which name may be used for a receive.
The result is local to the receiving task. It does not prove that senders failed or that the service disappeared; it means the current thread cannot legally wait on the requested object. Recreate or reacquire the correct receive endpoint before entering the next receive loop.
What to inspect
- Determine whether the name denotes a receive right, a send right, a dead name, a port set, or nothing in this task.
- Check whether a receive right was moved, deallocated, or placed in a port set by another thread.
- Use the designated port-set receive path when dispatching from several ports.
- Do not pass a port name between tasks without transferring the right through a supported mechanism.
References
- Mach Kernel Interface Reference: mach_msg
- Apple Kernel Programming Guide: Mach overview
- Apple XNU source: mach/message.h
Looking for a different code? Search another status or error code.
