diff options
author | tilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-08-10 19:15:57 +0000 |
---|---|---|
committer | tilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-08-10 19:15:57 +0000 |
commit | 8cae492343324ae845b8b19d78b253d824eac10f (patch) | |
tree | 3d0ab9b89a652c8bde68776be0e8b945b81aaa6b /codecs | |
parent | 9f4c1d7a4e1ee5f0ea1b21af53eb7357366ff661 (diff) |
AST-2009-005
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@211528 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'codecs')
-rw-r--r-- | codecs/codec_speex.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/codecs/codec_speex.c b/codecs/codec_speex.c index 6eff087d3..c2b4a4369 100644 --- a/codecs/codec_speex.c +++ b/codecs/codec_speex.c @@ -402,7 +402,7 @@ static void parse_config(void) } else ast_log(LOG_ERROR,"Error! Complexity must be 0-10\n"); } else if (!strcasecmp(var->name, "vbr_quality")) { - if (sscanf(var->value, "%f", &res_f) == 1 && res_f >= 0 && res_f <= 10) { + if (sscanf(var->value, "%30f", &res_f) == 1 && res_f >= 0 && res_f <= 10) { if (option_verbose > 2) ast_verbose(VERBOSE_PREFIX_3 "CODEC SPEEX: Setting VBR Quality to %f\n",res_f); vbr_quality = res_f; @@ -451,7 +451,7 @@ static void parse_config(void) if (option_verbose > 2) ast_verbose(VERBOSE_PREFIX_3 "CODEC SPEEX: Preprocessor AGC. [%s]\n",pp_agc ? "on" : "off"); } else if (!strcasecmp(var->name, "pp_agc_level")) { - if (sscanf(var->value, "%f", &res_f) == 1 && res_f >= 0) { + if (sscanf(var->value, "%30f", &res_f) == 1 && res_f >= 0) { if (option_verbose > 2) ast_verbose(VERBOSE_PREFIX_3 "CODEC SPEEX: Setting preprocessor AGC Level to %f\n",res_f); pp_agc_level = res_f; @@ -466,14 +466,14 @@ static void parse_config(void) if (option_verbose > 2) ast_verbose(VERBOSE_PREFIX_3 "CODEC SPEEX: Preprocessor Dereverb. [%s]\n",pp_dereverb ? "on" : "off"); } else if (!strcasecmp(var->name, "pp_dereverb_decay")) { - if (sscanf(var->value, "%f", &res_f) == 1 && res_f >= 0) { + if (sscanf(var->value, "%30f", &res_f) == 1 && res_f >= 0) { if (option_verbose > 2) ast_verbose(VERBOSE_PREFIX_3 "CODEC SPEEX: Setting preprocessor Dereverb Decay to %f\n",res_f); pp_dereverb_decay = res_f; } else ast_log(LOG_ERROR,"Error! Preprocessor Dereverb Decay must be >= 0\n"); } else if (!strcasecmp(var->name, "pp_dereverb_level")) { - if (sscanf(var->value, "%f", &res_f) == 1 && res_f >= 0) { + if (sscanf(var->value, "%30f", &res_f) == 1 && res_f >= 0) { if (option_verbose > 2) ast_verbose(VERBOSE_PREFIX_3 "CODEC SPEEX: Setting preprocessor Dereverb Level to %f\n",res_f); pp_dereverb_level = res_f; |