summaryrefslogtreecommitdiff
path: root/main
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2016-03-03 07:40:40 -0600
committerGerrit Code Review <gerrit2@gerrit.digium.api>2016-03-03 07:40:41 -0600
commitd7fe2becdd1c37b7afffe5f5adadf35ad58a4a24 (patch)
tree9f13c53e698474b0ca3631a926bb4671f26595bf /main
parent8140d7a8ef7077eca2f5be548750b3da68430f86 (diff)
parent25de01f3012ca074ebc78b5082c4a4607d642405 (diff)
Merge "SIP diversion: Fix REDIRECTING(reason) value inconsistencies."
Diffstat (limited to 'main')
-rw-r--r--main/callerid.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/main/callerid.c b/main/callerid.c
index 69fe6ff70..d2b321892 100644
--- a/main/callerid.c
+++ b/main/callerid.c
@@ -1209,7 +1209,16 @@ static const struct ast_value_translation redirecting_reason_types[] = {
{ AST_REDIRECTING_REASON_OUT_OF_ORDER, "out_of_order", "Called DTE Out-Of-Order" },
{ AST_REDIRECTING_REASON_AWAY, "away", "Callee is Away" },
{ AST_REDIRECTING_REASON_CALL_FWD_DTE, "cf_dte", "Call Forwarding By The Called DTE" },
- { AST_REDIRECTING_REASON_SEND_TO_VM, "send_to_vm", "Call is being redirected to user's voicemail"},
+ { AST_REDIRECTING_REASON_SEND_TO_VM, "send_to_vm", "Call is being redirected to user's voicemail" },
+
+ /* Convenience SIP aliases. Alias descriptions are not used. */
+ { AST_REDIRECTING_REASON_USER_BUSY, "user-busy" },
+ { AST_REDIRECTING_REASON_NO_ANSWER, "no-answer" },
+ { AST_REDIRECTING_REASON_UNCONDITIONAL, "unconditional" },
+ { AST_REDIRECTING_REASON_TIME_OF_DAY, "time-of-day" },
+ { AST_REDIRECTING_REASON_DO_NOT_DISTURB, "do-not-disturb" },
+ { AST_REDIRECTING_REASON_FOLLOW_ME, "follow-me" },
+ { AST_REDIRECTING_REASON_OUT_OF_ORDER, "out-of-service" },
/* *INDENT-ON* */
};
@@ -1232,7 +1241,7 @@ const char *ast_redirecting_reason_describe(int data)
for (index = 0; index < ARRAY_LEN(redirecting_reason_types); ++index) {
if (redirecting_reason_types[index].value == data) {
- return redirecting_reason_types[index].description;
+ return redirecting_reason_types[index].description ?: "Redirecting reason alias-bug";
}
}