From 8999372c33c0f188bd92eff24892302ede1bf6ad Mon Sep 17 00:00:00 2001
From: Mark Michelson <mmichelson@digium.com>
Date: Wed, 26 May 2010 20:04:51 +0000
Subject: [PATCH] Fix misspelling of macro args.

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@266092 65c4cc65-6c06-0410-ace0-fbb531ad65f3
---
 main/channel.c        | 2 +-
 res/res_musiconhold.c | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/main/channel.c b/main/channel.c
index 1dbe112655..999e39ba6e 100644
--- a/main/channel.c
+++ b/main/channel.c
@@ -7882,7 +7882,7 @@ int ast_channel_connected_line_macro(struct ast_channel *autoservice_chan, struc
 		? "CONNECTED_LINE_CALLER_SEND_MACRO" : "CONNECTED_LINE_CALLEE_SEND_MACRO");
 	macro = ast_strdupa(S_OR(macro, ""));
 	macro_args = pbx_builtin_getvar_helper(macro_chan, is_caller
-		? "CONNECTED_LINE_CALLER_SEND_MACRO_ARSG" : "CONNECTED_LINE_CALLEE_SEND_MACRO_ARGS");
+		? "CONNECTED_LINE_CALLER_SEND_MACRO_ARGS" : "CONNECTED_LINE_CALLEE_SEND_MACRO_ARGS");
 	macro_args = ast_strdupa(S_OR(macro_args, ""));
 	ast_channel_unlock(macro_chan);
 
diff --git a/res/res_musiconhold.c b/res/res_musiconhold.c
index 4d2c9ec49a..5527109c4a 100644
--- a/res/res_musiconhold.c
+++ b/res/res_musiconhold.c
@@ -1443,6 +1443,10 @@ static int local_ast_moh_start(struct ast_channel *chan, const char *mclass, con
 		}
 	}
 
+	if (ast_test_flag(global_flags, MOH_CACHERTCLASSES)) {
+		mohclass = get_mohbyname(mohclass->name, 0);
+	}
+
 	if (!mohclass) {
 		return -1;
 	}
-- 
GitLab