[zaptel-commits] sruffell: branch 1.4 r4495 - /branches/1.4/kernel/wctc4xxp/base.c
SVN commits to the Zaptel project
zaptel-commits at lists.digium.com
Wed Aug 20 14:31:57 CDT 2008
Author: sruffell
Date: Wed Aug 20 14:31:57 2008
New Revision: 4495
URL: http://svn.digium.com/view/zaptel?view=rev&rev=4495
Log:
Change to support both 5.3kbps and 6.3kbps bit rates when using the G723.1
codec.
Modified:
branches/1.4/kernel/wctc4xxp/base.c
Modified: branches/1.4/kernel/wctc4xxp/base.c
URL: http://svn.digium.com/view/zaptel/branches/1.4/kernel/wctc4xxp/base.c?view=diff&rev=4495&r1=4494&r2=4495
==============================================================================
--- branches/1.4/kernel/wctc4xxp/base.c (original)
+++ branches/1.4/kernel/wctc4xxp/base.c Wed Aug 20 14:31:57 2008
@@ -1678,13 +1678,13 @@
cpvt->last_dte_seqno = be16_to_cpu(packet->rtphdr.seqno);
} else {
rtp_eseq = ++cpvt->last_dte_seqno;
- if ( packet->rtphdr.seqno != rtp_eseq )
+ if ( be16_to_cpu(packet->rtphdr.seqno) != rtp_eseq )
DTE_DEBUG(DTE_DEBUG_GENERAL,
"Bad seqno from DTE! [%04X][%d][%d][%d]\n",
be16_to_cpu(packet->rtphdr.seqno),
(be16_to_cpu(packet->udphdr.dest) - 0x5000),
be16_to_cpu(packet->rtphdr.seqno),
- cpvt->last_dte_seqno);
+ rtp_eseq);
cpvt->last_dte_seqno = be16_to_cpu(packet->rtphdr.seqno);
}
@@ -1737,11 +1737,11 @@
}
if (ZT_FORMAT_G723_1 == dtc->srcfmt) {
- if (G723_5K_BYTES != count) {
+ if ((G723_5K_BYTES != count) && (G723_6K_BYTES != count)) {
DTE_DEBUG(DTE_DEBUG_GENERAL,
"Trying to transcode packet into G723 format " \
"that is %Zu bytes instead of the expected " \
- "%d bytes.\n", count, G723_5K_BYTES);
+ "%d/%d bytes.\n", count, G723_5K_BYTES, G723_6K_BYTES);
return -EINVAL;
}
cpvt->timestamp += G723_SAMPLES;
More information about the zaptel-commits
mailing list