]> git.saurik.com Git - apple/xnu.git/blob - osfmk/man/task_get_exception_ports.html
xnu-344.tar.gz
[apple/xnu.git] / osfmk / man / task_get_exception_ports.html
1 <h2>task_get_exception_ports</h2> <hr> <p> <strong>Function</strong> - Return send rights to the target task's exception ports. <h3>SYNOPSIS</h3> <pre> <strong>kern_return_t task_get_exception_ports</strong> <strong>(task_t</strong> <var>task</var>, <strong>exception_mask_t</strong> <var>exception_types</var>, <strong>exception_mask_array_t</strong> <var>old_exception_masks</var>, <strong>old_exception_masks</strong> <var>old_exception_count</var>, <strong>exception_port_array_t</strong> <var>old_exception_ports</var>, <strong>exception_behavior_array_t</strong> <var>old_behaviors</var>, <strong>exception_flavor_array_t</strong> <var>old_flavors</var><strong>);</strong> </pre> <h3>PARAMETERS</h3> <dl> <p> <dt> <var>task</var> <dd> [in task send right] The task for which to return the exception ports. <p> <dt> <var>exception_types</var> <dd> [in scalar] A flag word indicating the types of exceptions for which the exception ports are desired: <dl> <p> <dt> <strong>EXC_MASK_BAD_ACCESS</strong> <dd> Could not access memory. <p> <dt> <strong>EXC_MASK_BAD_INSTRUCTION</strong> <dd> Instruction failed. Illegal or undefined instruction or operand. <p> <dt> <strong>EXC_MASK_ARITHMETIC</strong> <dd> Arithmetic exception <p> <dt> <strong>EXC_MASK_EMULATION</strong> <dd> Emulation instruction. Emulation support instruction encountered. <p> <dt> <strong>EXC_MASK_SOFTWARE</strong> <dd> Software generated exception. <p> <dt> <strong>EXC_MASK_BREAKPOINT</strong> <dd> Trace, breakpoint, etc. <p> <dt> <strong>EXC_MASK_SYSCALL</strong> <dd> System call requested. <p> <dt> <strong>EXC_MASK_MACH_SYSCALL</strong> <dd> System call with a number in the Mach call range requested. <p> <dt> <strong>EXC_MASK_RPC_ALERT </strong> <dd> Exceptional condition encountered during execution of RPC. </dl> <p> <dt> <var>old_exception_masks</var> <dd> [out array of <var>exception_mask_t</var>] An array, each element being a mask specifying for which exception types the corresponding element of the other arrays apply. <p> <dt> <var>old_exception_count</var> <dd> [pointer to in/out scalar] On input, the maximum size of the array buffers; on output, the number of returned <exception type mask, exception port, behavior, flavor> sets returned. <p> <dt> <var>old_exception_ports</var> <dd> [out array of exception send rights] The returned exception ports. <p> <dt> <var>old_behaviors</var> <dd> [out array of <var>exception_behavior_t</var>] The type of exception message to be sent. Defined types are: <dl> <p> <dt> <strong>EXCEPTION_DEFAULT</strong> <dd> Send a <strong>catch_exception_raise</strong> message including the thread identity. <p> <dt> <strong>EXCEPTION_STATE</strong> <dd> Send a <strong>catch_exception_raise_state</strong> message including the thread state. <p> <dt> <strong>EXCEPTION_STATE_IDENTITY</strong> <dd> Send a <strong>catch_exception_raise_state_identity</strong> message including the thread identity and state. </dl> <p> <dt> <var>old_flavors</var> <dd> [out array of <var>thread_state_flavor_t</var>] The type of state to be sent with the exception message. These types are defined in <strong>&ltmach/thread_states.h&gt</strong>. </dl> <h3>DESCRIPTION</h3> <p> The <strong>task_get_exception_ports</strong> function returns send rights for a specified set of exception ports belonging to task. A task exception port is used when a thread specific exception port returns a non-success reply. The call returns a set of quadruples <exception type mask, exception port, behavior, flavor> for each unique set of <exception port, behavior, flavor> in effect for the task where the exception type mask indicates for which exception types the other values apply. <h3>RETURN VALUES</h3> <p> Only generic errors apply. <h3>RELATED INFORMATION</h3> <p> Functions: <a href="mach_task_self.html"><strong>mach_task_self</strong></a>, <a href="thread_get_exception_ports.html"><strong>thread_get_exception_ports</strong></a>, <a href="task_set_exception_ports.html"><strong>task_set_exception_ports</strong></a>, <a href="task_swap_exception_ports.html"><strong>task_swap_exception_ports</strong></a>, <a href="thread_create.html"><strong>thread_create</strong></a>, <a href="thread_set_exception_ports.html"><strong>thread_set_exception_ports</strong></a>, <a href="TS_exception_ports.html"><strong>thread_swap_exception_ports</strong></a>, <a href="catch_exception_raise.html"><strong>catch_exception_raise</strong></a>.