aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordvossel <dvossel@f38db490-d61c-443f-a65b-d21fe96a405b>2009-12-04 17:36:21 +0000
committerdvossel <dvossel@f38db490-d61c-443f-a65b-d21fe96a405b>2009-12-04 17:36:21 +0000
commit169876ec3fc99f2ad1c511aba74189342f41b738 (patch)
tree1777b64d38218303ee3cb25552b4878d2973651e
parent59a5477950287547111ce5447c70e82530d7cbc8 (diff)
Merged revisions 233121 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ................ r233121 | dvossel | 2009-12-04 11:22:31 -0600 (Fri, 04 Dec 2009) | 12 lines Merged revisions 233116 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r233116 | dvossel | 2009-12-04 11:21:34 -0600 (Fri, 04 Dec 2009) | 6 lines document and rename strip_control() in app_voicemail (closes issue #16291) Reported by: wdoekes ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@233165 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r--apps/app_voicemail.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c
index 04fe0156f..70c03ce5d 100644
--- a/apps/app_voicemail.c
+++ b/apps/app_voicemail.c
@@ -832,7 +832,13 @@ static int is_valid_dtmf(const char *key);
static int __has_voicemail(const char *context, const char *mailbox, const char *folder, int shortcircuit);
#endif
-static char *strip_control(const char *input, char *buf, size_t buflen)
+/*!
+ * \brief Strips control and non 7-bit clean characters from input string.
+ *
+ * \note To map control and none 7-bit characters to a 7-bit clean characters
+ * please use ast_str_encode_mine().
+ */
+static char *strip_control_and_high(const char *input, char *buf, size_t buflen)
{
char *bufptr = buf;
for (; *input; input++) {
@@ -4124,10 +4130,10 @@ static void make_email_file(FILE *p, char *srcemail, struct ast_vm_user *vmu, in
passdata2 = alloca(len_passdata2);
if (cidnum) {
- strip_control(cidnum, enc_cidnum, sizeof(enc_cidnum));
+ strip_control_and_high(cidnum, enc_cidnum, sizeof(enc_cidnum));
}
if (cidname) {
- strip_control(cidname, enc_cidname, sizeof(enc_cidname));
+ strip_control_and_high(cidname, enc_cidname, sizeof(enc_cidname));
}
gethostname(host, sizeof(host) - 1);