aboutsummaryrefslogtreecommitdiffstats
path: root/funcs/func_channel.c
diff options
context:
space:
mode:
Diffstat (limited to 'funcs/func_channel.c')
-rw-r--r--funcs/func_channel.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/funcs/func_channel.c b/funcs/func_channel.c
index d2e5c2c67..99f6d1e61 100644
--- a/funcs/func_channel.c
+++ b/funcs/func_channel.c
@@ -116,10 +116,10 @@ static int func_channel_write(struct ast_channel *chan, char *function,
} else if (!strcasecmp(data, "callgroup"))
chan->callgroup = ast_get_group(value);
else if (!strcasecmp(data, "txgain")) {
- sscanf(value, "%hhd", &gainset);
+ sscanf(value, "%4hhd", &gainset);
ast_channel_setoption(chan, AST_OPTION_TXGAIN, &gainset, sizeof(gainset), 0);
} else if (!strcasecmp(data, "rxgain")) {
- sscanf(value, "%hhd", &gainset);
+ sscanf(value, "%4hhd", &gainset);
ast_channel_setoption(chan, AST_OPTION_RXGAIN, &gainset, sizeof(gainset), 0);
} else if (!strcasecmp(data, "transfercapability")) {
unsigned short i;