mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-09 11:28:25 +00:00
Revert change to translate.c as it has caused an infinite loop to occur in circumstances.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@355721 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -517,9 +517,12 @@ static void rebuild_matrix(int samples)
|
|||||||
/* Is x->y->z a better choice than x->z?
|
/* Is x->y->z a better choice than x->z?
|
||||||
* There are three conditions for x->y->z to be a better choice than x->z
|
* There are three conditions for x->y->z to be a better choice than x->z
|
||||||
* 1. if there is no step directly between x->z then x->y->z is the best and only current option.
|
* 1. if there is no step directly between x->z then x->y->z is the best and only current option.
|
||||||
* 2. if x->y->z results in a more optimal sample rate conversion. */
|
* 2. if x->y->z costs less and the sample rate conversion is no less optimal.
|
||||||
|
* 3. if x->y->z results in a more optimal sample rate conversion. */
|
||||||
if (!tr_matrix[x][z].step) {
|
if (!tr_matrix[x][z].step) {
|
||||||
better_choice = 1;
|
better_choice = 1;
|
||||||
|
} else if ((newcost < tr_matrix[x][z].cost) && (new_rate_change <= tr_matrix[x][z].rate_change)) {
|
||||||
|
better_choice = 1;
|
||||||
} else if (new_rate_change < tr_matrix[x][z].rate_change) {
|
} else if (new_rate_change < tr_matrix[x][z].rate_change) {
|
||||||
better_choice = 1;
|
better_choice = 1;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user