<p>We have avp_copy on avpops module but we don’t have anything to copy xavps.</p>

<pre><code>// copy all the content of an avp to a xavp
$xavp(a[0]=>b) = $(avp(x)[*]);
// deleting left content
$xavp(a[0]=>b[*]) = $(avp(x)[*]);
// copy xavp to a xavp with index
$xavp(a[0]) = $xavp(b[1]);
// all
$xavp(a[*]) = $xavp(b[*]);
// copy all content of a xavp to a avp
$avp(x) = $xavp(a[0]=>b[*]);
</code></pre>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br>Reply to this email directly or <a href="https://github.com/kamailio/kamailio/issues/7">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AF36ZS8n_HO_g9L0N0SNtqRIJopsgkT7ks5nV3G7gaJpZM4DGWs6.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
  <div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
    <link itemprop="url" href="https://github.com/kamailio/kamailio/issues/7"></link>
    <meta itemprop="name" content="View Issue"></meta>
  </div>
  <meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>