[svn-commits] russell: branch 1.4 r94829 - in /branches/1.4: include/asterisk/ main/
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Thu Dec 27 08:44:30 CST 2007
Author: russell
Date: Thu Dec 27 08:44:29 2007
New Revision: 94829
URL: http://svn.digium.com/view/asterisk?view=rev&rev=94829
Log:
Use the constant that I really meant to use here ...
Modified:
branches/1.4/include/asterisk/translate.h
branches/1.4/main/translate.c
Modified: branches/1.4/include/asterisk/translate.h
URL: http://svn.digium.com/view/asterisk/branches/1.4/include/asterisk/translate.h?view=diff&rev=94829&r1=94828&r2=94829
==============================================================================
--- branches/1.4/include/asterisk/translate.h (original)
+++ branches/1.4/include/asterisk/translate.h Thu Dec 27 08:44:29 2007
@@ -23,7 +23,7 @@
#ifndef _ASTERISK_TRANSLATE_H
#define _ASTERISK_TRANSLATE_H
-//#define MAX_FORMAT 15 /* Do not include video here */
+#define MAX_AUDIO_FORMAT 15 /* Do not include video here */
#define MAX_FORMAT 32 /* Do include video here */
#if defined(__cplusplus) || defined(c_plusplus)
Modified: branches/1.4/main/translate.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/main/translate.c?view=diff&rev=94829&r1=94828&r2=94829
==============================================================================
--- branches/1.4/main/translate.c (original)
+++ branches/1.4/main/translate.c Thu Dec 27 08:44:29 2007
@@ -799,7 +799,7 @@
int common = ((*dst) & (*srcs)) & AST_FORMAT_AUDIO_MASK; /* are there common formats ? */
if (common) { /* yes, pick one and return */
- for (cur = 1, y = 0; y <= AST_FORMAT_MAX_AUDIO; cur <<= 1, y++) {
+ for (cur = 1, y = 0; y <= MAX_AUDIO_FORMAT; cur <<= 1, y++) {
if (cur & common) /* guaranteed to find one */
break;
}
@@ -808,10 +808,10 @@
return 0;
} else { /* No, we will need to translate */
AST_LIST_LOCK(&translators);
- for (cur = 1, y = 0; y <= AST_FORMAT_MAX_AUDIO; cur <<= 1, y++) {
+ for (cur = 1, y = 0; y <= MAX_AUDIO_FORMAT; cur <<= 1, y++) {
if (! (cur & *dst))
continue;
- for (cursrc = 1, x = 0; x <= AST_FORMAT_MAX_AUDIO; cursrc <<= 1, x++) {
+ for (cursrc = 1, x = 0; x <= MAX_AUDIO_FORMAT; cursrc <<= 1, x++) {
if (!(*srcs & cursrc) || !tr_matrix[x][y].step ||
tr_matrix[x][y].cost > besttime)
continue; /* not existing or no better */
More information about the svn-commits
mailing list