I'm unable to get rid of the \n in "multiline" content of a var.

xlog("var: $var(sdp)");
$var(sdp)=$(var(sdp){re.subst,/^a=rtcp:.*//});
xlog("var: $var(sdp)");

a=sendrecv#015#012a=rtcp:31543#015#012a=X-foo:bar
becomes:
a=sendrecv#015#012#012a=X-foo:bar

Using the s flag results in no substitution at all, /^a=rtcp:.*//s should 
result in
a=sendrecv#015#012
according to
http://www.kamailio.org/wiki/cookbooks/4.3.x/transformations#resubst_expression

Is this a bug or a feature? If it is a feature, how to get rid of the newline 
(without additional regexps substitutions).

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

Reply via email to