| @@ -347,6 +347,9 @@ sinc_mono_vari_process (SRC_PRIVATE *psrc, SRC_DATA *data) · 346 unmodified lines |
| 347 | | 347 | |
| 348 | src_ratio = psrc->last_ratio ; | 348 | src_ratio = psrc->last_ratio ; |
| 349 | | 349 | |
| | 350 | if (is_bad_src_ratio (src_ratio)) |
| | 351 | return SRC_ERR_BAD_INTERNAL_STATE ; |
| | 352 | |
| 350 | /* Check the sample rate ratio wrt the buffer len. */ | 353 | /* Check the sample rate ratio wrt the buffer len. */ |
| 351 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; | 354 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; |
| 352 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) | 355 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) |
| @@ -493,6 +496,9 @@ sinc_stereo_vari_process (SRC_PRIVATE *psrc, SRC_DATA *data) · 140 unmodified lines |
| 493 | | 496 | |
| 494 | src_ratio = psrc->last_ratio ; | 497 | src_ratio = psrc->last_ratio ; |
| 495 | | 498 | |
| | 499 | if (is_bad_src_ratio (src_ratio)) |
| | 500 | return SRC_ERR_BAD_INTERNAL_STATE ; |
| | 501 | |
| 496 | /* Check the sample rate ratio wrt the buffer len. */ | 502 | /* Check the sample rate ratio wrt the buffer len. */ |
| 497 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; | 503 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; |
| 498 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) | 504 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) |
| @@ -644,6 +650,9 @@ sinc_quad_vari_process (SRC_PRIVATE *psrc, SRC_DATA *data) · 145 unmodified lines |
| 644 | | 650 | |
| 645 | src_ratio = psrc->last_ratio ; | 651 | src_ratio = psrc->last_ratio ; |
| 646 | | 652 | |
| | 653 | if (is_bad_src_ratio (src_ratio)) |
| | 654 | return SRC_ERR_BAD_INTERNAL_STATE ; |
| | 655 | |
| 647 | /* Check the sample rate ratio wrt the buffer len. */ | 656 | /* Check the sample rate ratio wrt the buffer len. */ |
| 648 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; | 657 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; |
| 649 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) | 658 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) |
| @@ -801,6 +810,9 @@ sinc_hex_vari_process (SRC_PRIVATE *psrc, SRC_DATA *data) · 151 unmodified lines |
| 801 | | 810 | |
| 802 | src_ratio = psrc->last_ratio ; | 811 | src_ratio = psrc->last_ratio ; |
| 803 | | 812 | |
| | 813 | if (is_bad_src_ratio (src_ratio)) |
| | 814 | return SRC_ERR_BAD_INTERNAL_STATE ; |
| | 815 | |
| 804 | /* Check the sample rate ratio wrt the buffer len. */ | 816 | /* Check the sample rate ratio wrt the buffer len. */ |
| 805 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; | 817 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; |
| 806 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) | 818 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) |
| @@ -1045,6 +1057,9 @@ sinc_multichan_vari_process (SRC_PRIVATE *psrc, SRC_DATA *data) · 238 unmodified lines |
| 1045 | | 1057 | |
| 1046 | src_ratio = psrc->last_ratio ; | 1058 | src_ratio = psrc->last_ratio ; |
| 1047 | | 1059 | |
| | 1060 | if (is_bad_src_ratio (src_ratio)) |
| | 1061 | return SRC_ERR_BAD_INTERNAL_STATE ; |
| | 1062 | |
| 1048 | /* Check the sample rate ratio wrt the buffer len. */ | 1063 | /* Check the sample rate ratio wrt the buffer len. */ |
| 1049 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; | 1064 | count = (filter->coeff_half_len + 2.0) / filter->index_inc ; |
| 1050 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) | 1065 | if (MIN (psrc->last_ratio, data->src_ratio) < 1.0) |