1*e3723e1fSApple OSS Distributions<h2>mach_reply_port</h2> 2*e3723e1fSApple OSS Distributions<hr> 3*e3723e1fSApple OSS Distributions<p> 4*e3723e1fSApple OSS Distributions<strong>System Trap</strong> - Allocate a new port and insert corresponding receive right in the calling task. 5*e3723e1fSApple OSS Distributions<h3>SYNOPSIS</h3> 6*e3723e1fSApple OSS Distributions<pre> 7*e3723e1fSApple OSS Distributions<strong>#include<mach/mach_traps.h></strong> 8*e3723e1fSApple OSS Distributions 9*e3723e1fSApple OSS Distributions<strong>mach_port_t mach_reply_port( void )</strong> 10*e3723e1fSApple OSS Distributions</pre> 11*e3723e1fSApple OSS Distributions<h3>PARAMETERS</h3> 12*e3723e1fSApple OSS Distributions<dl> 13*e3723e1fSApple OSS DistributionsNone. 14*e3723e1fSApple OSS Distributions</dl> 15*e3723e1fSApple OSS Distributions<h3>DESCRIPTION</h3> 16*e3723e1fSApple OSS Distributions<p> 17*e3723e1fSApple OSS DistributionsThe <strong>mach_reply_port</strong> function creates a new port for 18*e3723e1fSApple OSS Distributionsthe current task and 19*e3723e1fSApple OSS Distributionsreturns the name assigned by the kernel. The kernel records 20*e3723e1fSApple OSS Distributionsthe name in the task's 21*e3723e1fSApple OSS Distributionsport name space and grants the task receive rights for the port. 22*e3723e1fSApple OSS DistributionsThe new port is 23*e3723e1fSApple OSS Distributionsnot a member of any port set. 24*e3723e1fSApple OSS Distributions<p> 25*e3723e1fSApple OSS DistributionsThis function is an optimized version of <strong>mach_port_allocate</strong> 26*e3723e1fSApple OSS Distributionsthat uses no port 27*e3723e1fSApple OSS Distributionsreferences. Its main purpose is to allocate a reply port for 28*e3723e1fSApple OSS Distributionsthe task when the task 29*e3723e1fSApple OSS Distributionsis starting, for example, before it has any ports to use as reply 30*e3723e1fSApple OSS Distributionsports for any IPC-based system functions. 31*e3723e1fSApple OSS Distributions<p> 32*e3723e1fSApple OSS DistributionsIf the task's task self port is null (thereby deactivating basic Mach 33*e3723e1fSApple OSS Distributionsmanipulations by the task), this call returns null. 34*e3723e1fSApple OSS Distributions<h3>CAUTIONS</h3> 35*e3723e1fSApple OSS Distributions<p> 36*e3723e1fSApple OSS DistributionsAlthough the created port can be used for any purpose, the implementation may 37*e3723e1fSApple OSS Distributionsoptimize its use as a reply port. 38*e3723e1fSApple OSS Distributions<h3>RETURN VALUES</h3> 39*e3723e1fSApple OSS Distributions<dl> 40*e3723e1fSApple OSS Distributions<dt> <strong>MACH_PORT_NULL</strong> 41*e3723e1fSApple OSS Distributions<dd> 42*e3723e1fSApple OSS DistributionsNo port was allocated. 43*e3723e1fSApple OSS Distributions <p> 44*e3723e1fSApple OSS Distributions<dt> [reply receive right] 45*e3723e1fSApple OSS Distributions<dd> 46*e3723e1fSApple OSS DistributionsAny other value indicates success. 47*e3723e1fSApple OSS Distributions</dl> 48*e3723e1fSApple OSS Distributions<h3>RELATED INFORMATION</h3> 49*e3723e1fSApple OSS Distributions<p> 50*e3723e1fSApple OSS DistributionsFunctions: 51*e3723e1fSApple OSS Distributions<a href="mach_port_allocate.html"><strong>mach_port_allocate</strong></a>. 52