diff options
author | pcadach <pcadach@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-11-16 08:18:41 +0000 |
---|---|---|
committer | pcadach <pcadach@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-11-16 08:18:41 +0000 |
commit | 5b74ecfcfac61fd058c22fb7c1ed89a0c7c118af (patch) | |
tree | 29695d43a2659c54d01f8a5ef2409a6c33fbe942 | |
parent | 558f435de463cf1fdb172d2875f7d4f95907fb17 (diff) |
Merged revisions 44809 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r44809 | pcadach | 2006-10-10 23:44:54 +0700 (Втр, 10 Окт 2006) | 1 line
CHANNEL() function sometime mix parameter and value
........
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@47718 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r-- | funcs/func_channel.c | 6 | ||||
-rw-r--r-- | include/asterisk/channel.h | 2 | ||||
-rw-r--r-- | main/channel.c | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/funcs/func_channel.c b/funcs/func_channel.c index 2a377b52f..9c02a59fa 100644 --- a/funcs/func_channel.c +++ b/funcs/func_channel.c @@ -112,13 +112,13 @@ static int func_channel_write(struct ast_channel *chan, char *function, locked_string_field_set(chan, musicclass, value); else if (!strcasecmp(data, "tonezone")) { struct tone_zone *new_zone; - if (!(new_zone = ast_get_indication_zone(data))) { - ast_log(LOG_ERROR, "Unknown country code for tonezone. Check indications.conf for available country codes.\n"); + if (!(new_zone = ast_get_indication_zone(value))) { + ast_log(LOG_ERROR, "Unknown country code '%s' for tonezone. Check indications.conf for available country codes.\n", value); ret = -1; } else chan->zone = new_zone; } else if (!strcasecmp(data, "callgroup")) - chan->callgroup = ast_get_group(data); + chan->callgroup = ast_get_group(value); else if (!strcasecmp(data, "txgain")) { sscanf(value, "%hhd", &gainset); ast_channel_setoption(chan, AST_OPTION_TXGAIN, &gainset, sizeof(gainset), 0); diff --git a/include/asterisk/channel.h b/include/asterisk/channel.h index 10491a041..83a459806 100644 --- a/include/asterisk/channel.h +++ b/include/asterisk/channel.h @@ -1323,7 +1323,7 @@ static inline int ast_select(int nfds, fd_set *rfds, fd_set *wfds, fd_set *efds, ast_set_flag(c, AST_FLAG_BLOCKING); \ } } -ast_group_t ast_get_group(char *s); +ast_group_t ast_get_group(const char *s); /*! \brief print call- and pickup groups into buffer */ char *ast_print_group(char *buf, int buflen, ast_group_t group); diff --git a/main/channel.c b/main/channel.c index a1fc401d3..8dff68a65 100644 --- a/main/channel.c +++ b/main/channel.c @@ -4193,7 +4193,7 @@ int ast_tonepair(struct ast_channel *chan, int freq1, int freq2, int duration, i return 0; } -ast_group_t ast_get_group(char *s) +ast_group_t ast_get_group(const char *s) { char *piece; char *c; |