--- asterisk-1.8.15.0-CLEAN/main/say.c 2012-06-15 11:56:08.000000000 -0400 +++ asterisk-1.8.15.0-0.2.0/main/say.c 2013-01-17 14:43:54.000000000 -0500 @@ -60,13 +60,14 @@ static int wait_file(struct ast_channel *chan, const char *ints, const char *file, const char *lang); -static int say_character_str_full(struct ast_channel *chan, const char *str, const char *ints, const char *lang, int audiofd, int ctrlfd) +static int say_character_str_full(struct ast_channel *chan, const char *str, const char *ints, const char *lang, int casesensitive, int audiofd, int ctrlfd) { const char *fn; char fnbuf[10], asciibuf[20] = "letters/ascii"; char ltr; int num = 0; int res = 0; + int upper = 0; while (str[num] && !res) { fn = NULL; @@ -120,9 +121,18 @@ break; default: ltr = str[num]; - if ('A' <= ltr && ltr <= 'Z') ltr += 'a' - 'A'; /* file names are all lower-case */ - strcpy(fnbuf, "letters/X"); - fnbuf[8] = ltr; + if ('A' <= ltr && ltr <= 'Z') { + ltr += 'a' - 'A'; /* file names are all lower-case */ + if (casesensitive) { + upper = !upper; + } + } + if (upper) { + strcpy(fnbuf, "uppercase"); + } else { + strcpy(fnbuf, "letters/X"); + fnbuf[8] = ltr; + } fn = fnbuf; } if ((fn && ast_fileexists(fn, NULL, lang) > 0) || @@ -136,6 +146,9 @@ } ast_stopstream(chan); } + if (upper) { + continue; + } num++; }