summaryrefslogtreecommitdiff
path: root/pbx
diff options
context:
space:
mode:
authorMatthew Jordan <mjordan@digium.com>2014-07-04 13:26:37 +0000
committerMatthew Jordan <mjordan@digium.com>2014-07-04 13:26:37 +0000
commit97834718c283d74e3571c1bf52d2840b93157cda (patch)
treea5887ff82e9f3d33c4cc1e64c0f9804dae47c295 /pbx
parent3bd495a688199c2db5ebc397210f06191aa59581 (diff)
Remove many deprecated modules
Billing records are fair, To get paid is quite bright, You should really use ODBC; Good-bye cdr_sqlite. Microsoft did once push H.323, Hell, we all remember NetMeeting. But try to compile chan_h323 now And you will take quite a beating. The XMPP and SIP war was fierce, And in the distant fray Was birthed res_jabber/chan_jingle; But neither to stay. For everyone did care and chase what Google professed. "Free Internet Calling" was what devotees cried, But Google did change the specs so often That the developers were happy the day chan_gtalk died. And then there was that odd application Dedicated to the Polish tongue. app_saycountpl was subsumed by Say; One could say its bell was rung. To read and parse a file from the dialplan You could (I guess) use an application. app_readfile did fill that purpose, but I think A function is perhaps better in its creation. Barging is rude, I'm not sure why we do it. Inwardly, the caller will probably sigh. But if you really must do it, Don't use app_dahdibarge, use ChanSpy. We all despise the sound of tinny robots It makes our queues so cold. To control such an abomination It's better to not use Wait/SetMusicOnHold. It's often nice to know properties of a channel It makes our calls right We have a nice function called CHANNEL And so SIPCHANINFO is sent off into the night. And now things get odd; Apparently one could delimit with a colon Properties from the SIPPEER function! Commas are in; all others are done. Finally, a word on pipes and commas. We're sorry. We can't say it enough. But those compatibility options in asterisk.conf; To maintain them forever was just too tough. This patch removes: * cdr_sqlite * chan_gtalk * chan_jingle * chan_h323 * res_jabber * app_saycountpl * app_readfile * app_dahdibarge It removes the following applications/functions: * WaitMusicOnHold * SetMusicOnHold * SIPCHANINFO It removes the colon delimiter from the SIPPEER function. Finally, it also removes all compatibility options that were configurable from asterisk.conf, as these all applied to compatibility with Asterisk 1.4 systems. Review: https://reviewboard.asterisk.org/r/3698/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@418019 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'pbx')
-rw-r--r--pbx/pbx_realtime.c32
1 files changed, 4 insertions, 28 deletions
diff --git a/pbx/pbx_realtime.c b/pbx/pbx_realtime.c
index 7624d5979..1143fb45a 100644
--- a/pbx/pbx_realtime.c
+++ b/pbx/pbx_realtime.c
@@ -303,7 +303,7 @@ static int realtime_exec(struct ast_channel *chan, const char *context, const ch
struct ast_variable *var = realtime_common(context, exten, priority, data, MODE_MATCH);
if (var) {
- char *tmp="";
+ char *appdata_tmp = "";
char *app = NULL;
struct ast_variable *v;
@@ -311,31 +311,7 @@ static int realtime_exec(struct ast_channel *chan, const char *context, const ch
if (!strcasecmp(v->name, "app"))
app = ast_strdupa(v->value);
else if (!strcasecmp(v->name, "appdata")) {
- if (ast_compat_pbx_realtime) {
- char *ptr;
- int in = 0;
- tmp = ast_alloca(strlen(v->value) * 2 + 1);
- for (ptr = tmp; *v->value; v->value++) {
- if (*v->value == ',') {
- *ptr++ = '\\';
- *ptr++ = ',';
- } else if (*v->value == '|' && !in) {
- *ptr++ = ',';
- } else {
- *ptr++ = *v->value;
- }
-
- /* Don't escape '|', meaning 'or', inside expressions ($[ ]) */
- if (v->value[0] == '[' && v->value[-1] == '$') {
- in++;
- } else if (v->value[0] == ']' && in) {
- in--;
- }
- }
- *ptr = '\0';
- } else {
- tmp = ast_strdupa(v->value);
- }
+ appdata_tmp = ast_strdupa(v->value);
}
}
ast_variables_destroy(var);
@@ -350,8 +326,8 @@ static int realtime_exec(struct ast_channel *chan, const char *context, const ch
RAII_VAR(struct stasis_message *, msg, NULL, ao2_cleanup);
appdata[0] = 0; /* just in case the substitute var func isn't called */
- if(!ast_strlen_zero(tmp))
- pbx_substitute_variables_helper(chan, tmp, appdata, sizeof(appdata) - 1);
+ if(!ast_strlen_zero(appdata_tmp))
+ pbx_substitute_variables_helper(chan, appdata_tmp, appdata, sizeof(appdata) - 1);
ast_verb(3, "Executing [%s@%s:%d] %s(\"%s\", \"%s\")\n",
ast_channel_exten(chan), ast_channel_context(chan), ast_channel_priority(chan),
term_color(tmp1, app, COLOR_BRCYAN, 0, sizeof(tmp1)),