-<h2>vm_copy</h2>\r<hr>\r<p>\r<strong>Function</strong> - Copy a region of virtual memory.\r<h3>SYNOPSIS</h3>\r<pre>\r<strong>kern_return_t vm_copy</strong>\r <strong>(vm_task_t</strong> <var>target_task</var>,\r <strong>vm_address_t</strong> <var>source_address</var>,\r <strong>vm_size_t</strong> <var>count</var>,\r <strong>vm_address_t</strong> <var>dest_address</var><strong>);</strong>\r</pre>\r<h3>PARAMETERS</h3>\r<dl>\r<p>\r<dt> <var>target_task</var> \r<dd>\r[in task send right]\rThe port for the task whose memory is to be copied.\r<p>\r<dt> <var>source_address</var> \r<dd>\r[in scalar]\rThe starting address for the source region. The address must \rbe on a page boundary.\r<p>\r<dt> <var>count</var> \r<dd>\r[in scalar]\rThe number of bytes in the source region. The number of \rbytes must convert to an integral number of virtual pages.\r<p>\r<dt> <var>dest_address</var> \r<dd>\r[in scalar]\rThe starting address for the destination region. The address \rmust be on a page boundary.\r</dl>\r<h3>DESCRIPTION</h3>\r<p>\rThe <strong>vm_copy</strong> function copies a source region to a destination\rregion within the \rsame task's virtual memory. It is semantically equivalent to\r<strong>vm_read</strong> followed \rby <strong>vm_write</strong>. The destination region can overlap the source region.\r<p>\rThe destination region must already be allocated. The source region must be \rreadable, and the destination region must be writable.\r<h3>NOTES</h3>\r<p>\rThis interface is machine word length specific because of the virtual address\rparameter.\r<h3>RETURN VALUES</h3>\r<dl>\r<p>\r<dt> <strong>KERN_PROTECTION_FAILURE</strong>\r<dd>\rThe source region is protected against reading, or the destination\rregion is protected against writing.\r<p>\r<dt> <strong>KERN_INVALID_ADDRESS</strong>\r<dd>\rAn address is illegal or specifies a non-allocated region, or there is not \renough memory following one of the addresses.\r</dl>\r<h3>RELATED INFORMATION</h3>\r<p>\rFunctions:\r<a href="vm_protect.html"><strong>vm_protect</strong></a>,\r<a href="vm_read.html"><strong>vm_read</strong></a>,\r<a href="vm_write.html"><strong>vm_write</strong></a>,\r<a href="host_page_size.html"><strong>host_page_size</strong></a>.\r
\ No newline at end of file
+<h2>vm_copy</h2>
+<hr>
+<p>
+<strong>Function</strong> - Copy a region of virtual memory.
+<h3>SYNOPSIS</h3>
+<pre>
+<strong>kern_return_t vm_copy</strong>
+ <strong>(vm_task_t</strong> <var>target_task</var>,
+ <strong>vm_address_t</strong> <var>source_address</var>,
+ <strong>vm_size_t</strong> <var>count</var>,
+ <strong>vm_address_t</strong> <var>dest_address</var><strong>);</strong>
+</pre>
+<h3>PARAMETERS</h3>
+<dl>
+<p>
+<dt> <var>target_task</var>
+<dd>
+[in task send right]
+The port for the task whose memory is to be copied.
+<p>
+<dt> <var>source_address</var>
+<dd>
+[in scalar]
+The starting address for the source region. The address must
+be on a page boundary.
+<p>
+<dt> <var>count</var>
+<dd>
+[in scalar]
+The number of bytes in the source region. The number of
+bytes must convert to an integral number of virtual pages.
+<p>
+<dt> <var>dest_address</var>
+<dd>
+[in scalar]
+The starting address for the destination region. The address
+must be on a page boundary.
+</dl>
+<h3>DESCRIPTION</h3>
+<p>
+The <strong>vm_copy</strong> function copies a source region to a destination
+region within the
+same task's virtual memory. It is semantically equivalent to
+<strong>vm_read</strong> followed
+by <strong>vm_write</strong>. The destination region can overlap the source region.
+<p>
+The destination region must already be allocated. The source region must be
+readable, and the destination region must be writable.
+<h3>NOTES</h3>
+<p>
+This interface is machine word length specific because of the virtual address
+parameter.
+<h3>RETURN VALUES</h3>
+<dl>
+<p>
+<dt> <strong>KERN_PROTECTION_FAILURE</strong>
+<dd>
+The source region is protected against reading, or the destination
+region is protected against writing.
+<p>
+<dt> <strong>KERN_INVALID_ADDRESS</strong>
+<dd>
+An address is illegal or specifies a non-allocated region, or there is not
+enough memory following one of the addresses.
+</dl>
+<h3>RELATED INFORMATION</h3>
+<p>
+Functions:
+<a href="vm_protect.html"><strong>vm_protect</strong></a>,
+<a href="vm_read.html"><strong>vm_read</strong></a>,
+<a href="vm_write.html"><strong>vm_write</strong></a>,
+<a href="host_page_size.html"><strong>host_page_size</strong></a>.