[SR-Users] q-value on unsupported clients

Daniel W. Graham dan at cmsinter.net
Thu Nov 5 18:37:28 CET 2015


This explains a lot, I definitely wasn't aware. 

Thanks for the explanation!



-----Original Message-----
From: sr-users [mailto:sr-users-bounces at lists.sip-router.org] On Behalf Of Olle E. Johansson
Sent: Thursday, November 5, 2015 4:23 AM
To: Kamailio (SER) - Users Mailing List <sr-users at lists.sip-router.org>
Subject: Re: [SR-Users] q-value on unsupported clients


> On 05 Nov 2015, at 10:15, Daniel Tryba <d.tryba at pocos.nl> wrote:
> 
>> Based on the xlog output, the following doesn't appear to be working 
>> - remove_hf("Contact");
>> append_hf("Contact: $var(newct)\r\n");
>> 
>> I've actually had a similar issue before replacing a hdr so I'm 
>> wondering if I'm doing something wrong?
> 
> Header manipulation is doesn't update the already parsed message that 
> is being used for $hdr etc.
This is an important fact for all routing scripts. You have one message in memory that you read from and one copy that you apply changes on. The changes are applied when you send the message or when you run the function below.

> You have to apply the changes with
> http://kamailio.org/docs/modules/stable/modules/textopsx.html#textopsx
> .f.msg_apply_changes

Not that if you run this function you owerwrite the incoming message and have no way of going back to the original incoming message. 

/O
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users at lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




More information about the sr-users mailing list