[OpenSIPS-Users] codec_delete_except_re() and RFC2833

Jeff Pyle jpyle at fidelityvoice.com
Fri Aug 16 23:36:06 CEST 2013


Hello,

This is on OpenSIPS 1.9.

I want to remove all audio codecs except PCMU from an SDP.  I have the
following config:

        if (codec_exists("PCMU")) {
                codec_delete_except_re("PCMU");
        } else {
                send_reply("488", "PCMU required");
                exit;
        }

It does exactly what it's supposed to do, leaving only PCMU in the SDP.
 The problem is that it also removes the RFC2833 definition.

Codecs in:

m=audio 16414 RTP/AVP 9 0 18 101.
a=rtpmap:9 G722/8000.
a=rtpmap:0 PCMU/8000.
a=rtpmap:18 G729/8000.
a=fmtp:18 annexb=no.
a=rtpmap:101 telephone-event/8000.


Codecs out:

m=audio 16414 RTP/AVP 0 .
a=rtpmap:0 PCMU/8000.

Perhaps the correct question to ask is how to delete everything except PCMU
*and* telephone-event?



Regards,
Jeff
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20130816/185f16f7/attachment.htm>


More information about the Users mailing list