]> git.saurik.com Git - apple/xnu.git/blame - osfmk/man/task_get_exception_ports.html
xnu-344.tar.gz
[apple/xnu.git] / osfmk / man / task_get_exception_ports.html
CommitLineData
9bccf70c 1<h2>task_get_exception_ports</h2>\r<hr>\r<p>\r<strong>Function</strong> - Return send rights to the target task's exception ports.\r<h3>SYNOPSIS</h3>\r<pre>\r<strong>kern_return_t task_get_exception_ports</strong>\r <strong>(task_t</strong> <var>task</var>,\r <strong>exception_mask_t</strong> <var>exception_types</var>,\r <strong>exception_mask_array_t</strong> <var>old_exception_masks</var>,\r <strong>old_exception_masks</strong> <var>old_exception_count</var>,\r <strong>exception_port_array_t</strong> <var>old_exception_ports</var>,\r <strong>exception_behavior_array_t</strong> <var>old_behaviors</var>,\r <strong>exception_flavor_array_t</strong> <var>old_flavors</var><strong>);</strong>\r</pre>\r<h3>PARAMETERS</h3>\r<dl>\r<p>\r<dt> <var>task</var> \r<dd>\r[in task send right]\rThe task for which to return the exception ports.\r<p>\r<dt> <var>exception_types</var> \r<dd>\r[in scalar]\rA flag word indicating the types of exceptions for which the \rexception ports are desired:\r<dl>\r<p>\r<dt> <strong>EXC_MASK_BAD_ACCESS</strong>\r<dd>\rCould not access memory.\r<p>\r<dt> <strong>EXC_MASK_BAD_INSTRUCTION</strong>\r<dd>\rInstruction failed. Illegal or undefined instruction or operand.\r<p>\r<dt> <strong>EXC_MASK_ARITHMETIC</strong>\r<dd>\rArithmetic exception\r<p>\r<dt> <strong>EXC_MASK_EMULATION</strong>\r<dd>\rEmulation instruction. Emulation support instruction\rencountered.\r<p>\r<dt> <strong>EXC_MASK_SOFTWARE</strong>\r<dd>\rSoftware generated exception.\r<p>\r<dt> <strong>EXC_MASK_BREAKPOINT</strong>\r<dd>\rTrace, breakpoint, etc.\r<p>\r<dt> <strong>EXC_MASK_SYSCALL</strong>\r<dd>\rSystem call requested.\r<p>\r<dt> <strong>EXC_MASK_MACH_SYSCALL</strong>\r<dd>\rSystem call with a number in the Mach call range requested.\r<p>\r<dt> <strong>EXC_MASK_RPC_ALERT </strong>\r<dd>\rExceptional condition encountered during execution of RPC.\r</dl>\r<p>\r<dt> <var>old_exception_masks</var> \r<dd>\r[out array of <var>exception_mask_t</var>]\rAn array, each element being a mask \rspecifying for which exception types the corresponding element of the \rother arrays apply.\r<p>\r<dt> <var>old_exception_count</var> \r<dd>\r[pointer to in/out scalar]\rOn input, the maximum size of the array\rbuffers; on output, the number of returned <exception type mask,\rexception port, behavior, flavor> sets returned.\r<p>\r<dt> <var>old_exception_ports</var> \r<dd>\r[out array of exception send rights]\rThe returned exception ports.\r<p>\r<dt> <var>old_behaviors</var> \r<dd>\r[out array of <var>exception_behavior_t</var>]\rThe type of exception message to \rbe sent. Defined types are:\r<dl>\r<p>\r<dt> <strong>EXCEPTION_DEFAULT</strong>\r<dd>\rSend a <strong>catch_exception_raise</strong> message including the thread identity.\r<p>\r<dt> <strong>EXCEPTION_STATE</strong>\r<dd>\rSend a <strong>catch_exception_raise_state</strong> message including the \rthread state.\r<p>\r<dt> <strong>EXCEPTION_STATE_IDENTITY</strong>\r<dd>\rSend a <strong>catch_exception_raise_state_identity</strong> message\rincluding the thread identity and state.\r</dl>\r<p>\r<dt> <var>old_flavors</var> \r<dd>\r[out array of <var>thread_state_flavor_t</var>]\rThe type of state to be sent with \rthe exception message. These types are defined in <strong>&ltmach/thread_states.h&gt</strong>.\r</dl>\r<h3>DESCRIPTION</h3>\r<p>\rThe <strong>task_get_exception_ports</strong> function returns send\rrights for a specified set \rof exception ports belonging to task. A task exception port is used when a \rthread specific exception port returns a non-success reply. \rThe call returns a set \rof quadruples <exception type mask, exception port, behavior, flavor> for each \runique set of <exception port, behavior, flavor> in effect for\rthe task where the \rexception type mask indicates for which exception types the other values apply.\r<h3>RETURN VALUES</h3>\r<p>\rOnly generic errors apply.\r<h3>RELATED INFORMATION</h3>\r<p>\rFunctions:\r<a href="mach_task_self.html"><strong>mach_task_self</strong></a>,\r<a href="thread_get_exception_ports.html"><strong>thread_get_exception_ports</strong></a>,\r<a href="task_set_exception_ports.html"><strong>task_set_exception_ports</strong></a>,\r<a href="task_swap_exception_ports.html"><strong>task_swap_exception_ports</strong></a>,\r<a href="thread_create.html"><strong>thread_create</strong></a>,\r<a href="thread_set_exception_ports.html"><strong>thread_set_exception_ports</strong></a>,\r<a href="TS_exception_ports.html"><strong>thread_swap_exception_ports</strong></a>,\r<a href="catch_exception_raise.html"><strong>catch_exception_raise</strong></a>.\r