[OpenSIPS-Users] overwriting AVPs at certain index

Jayesh Nambiar jayesh.voip at gmail.com
Tue Nov 2 10:51:06 CET 2010


Hi All,
I am trying to overwrite certain values at specific index of AVP and it
doesn't work as expected. How I do it is:

$avp(variable) = $avp(value1);
$avp(i:999) = 0;
$(avp(variable)[$avp(i:999)]) = $avp(value2);

While executing this, opensips logs an error saying unable to replace AVPs.
Is the syntax wrong somewhere? I do this as I don't want to add multiple
values into single AVP and also I dont want to call avp_delete function
before assigning a new value to the AVP. Moreover the value at $avp(i:999)
can change and thus it is assigned to another AVP.

Any help related to AVP overwriting function would be very helpful.

--- Jayesh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.opensips.org/pipermail/users/attachments/20101102/9ccb011f/attachment.htm 


More information about the Users mailing list