1 <h2>mach_ports_lookup
</h2>
4 <strong>Function
</strong> - Provide caller with an array of the target task's well-known ports.
7 <strong>kern_return_t mach_ports_lookup
</strong>
8 <strong>(task_t
</strong> <var>target_task
</var>,
9 <strong>mach_port_array_t
</strong> <var>init_port_set
</var>,
10 <strong>mach_msg_type_number_t
</strong> <var>init_port_count
</var><strong>);
</strong>
15 <dt> <var>target_task
</var>
18 The task whose currently registered ports are to be
21 <dt> <var>init_port_set
</var>
23 [out pointer to dynamic array of registered send rights]
27 <dt> <var>init_port_count
</var>
30 The number of returned port rights.
34 The
<strong>mach_ports_lookup
</strong> function returns an array of
36 ports that are currently registered for the specified task.
37 Note that the task holds
38 only send rights for the ports.
40 Registered ports are those ports that are used by the run-time
41 system to initialize a task. To register system ports for a task,
42 use the
<strong>mach_ports_register
</strong> function.
43 <h3>RETURN VALUES
</h3>
45 Only generic errors apply.
46 <h3>RELATED INFORMATION
</h3>
49 <a href=
"mach_ports_register.html"><strong>mach_ports_register
</strong></a>.