[svn-commits] qwell: branch 1.4 r89046 - /branches/1.4/codecs/codec_zap.c
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Tue Nov 6 13:09:31 CST 2007
Author: qwell
Date: Tue Nov 6 13:09:30 2007
New Revision: 89046
URL: http://svn.digium.com/view/asterisk?view=rev&rev=89046
Log:
Correctly set the total number of channels from a zaptel transcoder board.
SPD-49, patch by Matthew Nicholson.
Modified:
branches/1.4/codecs/codec_zap.c
Modified: branches/1.4/codecs/codec_zap.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/codecs/codec_zap.c?view=diff&rev=89046&r1=89045&r2=89046
==============================================================================
--- branches/1.4/codecs/codec_zap.c (original)
+++ branches/1.4/codecs/codec_zap.c Tue Nov 6 13:09:30 2007
@@ -224,7 +224,6 @@
if (ioctl(ztp->fd, ZT_TRANSCODE_OP, &x))
ast_log(LOG_WARNING, "Failed to release transcoder channel: %s\n", strerror(errno));
- ast_atomic_fetchadd_int(&channels.total, -1);
switch (ztp->hdr->dstfmt) {
case AST_FORMAT_G729A:
case AST_FORMAT_G723_1:
@@ -286,7 +285,6 @@
ztp->fd = fd;
ztp->hdr = hdr;
- ast_atomic_fetchadd_int(&channels.total, +1);
switch (hdr->dstfmt) {
case AST_FORMAT_G729A:
case AST_FORMAT_G723_1:
@@ -442,6 +440,7 @@
if (option_verbose > 1)
ast_verbose(VERBOSE_PREFIX_2 "Found transcoder '%s'.\n", info.name);
build_translators(&map, info.dstfmts, info.srcfmts);
+ ast_atomic_fetchadd_int(&channels.total, info.numchannels / 2);
}
close(fd);
More information about the svn-commits
mailing list