Module: sems Branch: master Commit: 5af3eecee1e83089f5bd16281e980afd38f3d339 URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sems/?a=commit;h=5af3eecee1e83089f5bd16281e980afd38f3d339
Author: Raphael Coeffic <[email protected]> Committer: Raphael Coeffic <[email protected]> Date: Mon Mar 5 08:35:55 2012 +0100 b/f: fix dynamic payload matching. - encoding name is case-insensitive - matching on advertised sample rate, as this is the clock rate used in the SDP. --- core/AmPlugIn.cpp | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/AmPlugIn.cpp b/core/AmPlugIn.cpp index f98ee3f..723f490 100644 --- a/core/AmPlugIn.cpp +++ b/core/AmPlugIn.cpp @@ -413,8 +413,8 @@ int AmPlugIn::getDynPayload(const string& name, int rate, int encoding_param) co // find a dynamic payload by name/rate and encoding_param (channels, if > 0) for(std::map<int, amci_payload_t*>::const_iterator pl_it = payloads.begin(); pl_it != payloads.end(); ++pl_it) - if( (name == pl_it->second->name) - && (rate == pl_it->second->sample_rate) ) { + if( (!strcasecmp(name.c_str(),pl_it->second->name) + && (rate == pl_it->second->advertised_sample_rate)) ) { if ((encoding_param > 0) && (pl_it->second->channels > 0) && (encoding_param != pl_it->second->channels)) continue; _______________________________________________ Semsdev mailing list [email protected] http://lists.iptel.org/mailman/listinfo/semsdev
