aboutsummaryrefslogtreecommitdiffstats
path: root/codecs/codec_ulaw.c
diff options
context:
space:
mode:
authormmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b>2010-06-03 17:09:11 +0000
committermmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b>2010-06-03 17:09:11 +0000
commit6890baac638fc37a1c4c615ac8fda2251641dc3d (patch)
tree1f2066e925b5c8961f31cf4d7310f0e628845827 /codecs/codec_ulaw.c
parent8f5a23ad5ee7ef73a1d81e0fbb14808ab0d28d3a (diff)
Remove unnecessary code relating to PLC.
The logic for handling generic PLC is now handled in ast_write in channel.c instead of in translation code. Review: https://reviewboard.asterisk.org/r/683/ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@267492 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'codecs/codec_ulaw.c')
-rw-r--r--codecs/codec_ulaw.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/codecs/codec_ulaw.c b/codecs/codec_ulaw.c
index 9ed9d550d..07f5da39d 100644
--- a/codecs/codec_ulaw.c
+++ b/codecs/codec_ulaw.c
@@ -84,7 +84,6 @@ static struct ast_translator ulawtolin = {
.sample = ulaw_sample,
.buffer_samples = BUFFER_SAMPLES,
.buf_size = BUFFER_SAMPLES * 2,
- .plc_samples = 160,
};
static struct ast_translator testlawtolin = {
@@ -95,7 +94,6 @@ static struct ast_translator testlawtolin = {
.sample = ulaw_sample,
.buffer_samples = BUFFER_SAMPLES,
.buf_size = BUFFER_SAMPLES * 2,
- .plc_samples = 160,
};
/*!
@@ -122,27 +120,8 @@ static struct ast_translator lintotestlaw = {
.buffer_samples = BUFFER_SAMPLES,
};
-static int parse_config(int reload)
-{
- struct ast_variable *var;
- struct ast_flags config_flags = { reload ? CONFIG_FLAG_FILEUNCHANGED : 0 };
- struct ast_config *cfg = ast_config_load("codecs.conf", config_flags);
- if (cfg == CONFIG_STATUS_FILEMISSING || cfg == CONFIG_STATUS_FILEUNCHANGED || cfg == CONFIG_STATUS_FILEINVALID)
- return 0;
- for (var = ast_variable_browse(cfg, "plc"); var; var = var->next) {
- if (!strcasecmp(var->name, "genericplc")) {
- ulawtolin.useplc = ast_true(var->value) ? 1 : 0;
- ast_verb(3, "codec_ulaw: %susing generic PLC\n", ulawtolin.useplc ? "" : "not ");
- }
- }
- ast_config_destroy(cfg);
- return 0;
-}
-
static int reload(void)
{
- if (parse_config(1))
- return AST_MODULE_LOAD_DECLINE;
return AST_MODULE_LOAD_SUCCESS;
}
@@ -162,8 +141,6 @@ static int load_module(void)
{
int res;
- if (parse_config(0))
- return AST_MODULE_LOAD_DECLINE;
res = ast_register_translator(&ulawtolin);
if (!res) {
res = ast_register_translator(&lintoulaw);