Index: say.c =================================================================== --- say.c (revision 41266) +++ say.c (working copy) @@ -5097,6 +5097,13 @@ } /* Taiwanese / Chinese syntax */ +/* Extra files used: + * digits/year + * digits/day + * digits/minute + * digits/second + * (oclock contains the chinese for "hour", and "month" is included in the mon-%d files) + */ int ast_say_date_with_format_tw(struct ast_channel *chan, time_t time, const char *ints, const char *lang, const char *format, const char *timezone) { struct tm tm; @@ -5140,18 +5147,10 @@ break; case 'd': case 'e': - /* First - Thirtyfirst */ - if (!(tm.tm_mday % 10) || (tm.tm_mday < 10)) { - snprintf(nextmsg,sizeof(nextmsg), "digits/h-%d", tm.tm_mday); - res = wait_file(chan,ints,nextmsg,lang); - } else { - snprintf(nextmsg,sizeof(nextmsg), "digits/h-%dh", tm.tm_mday - (tm.tm_mday % 10)); - res = wait_file(chan,ints,nextmsg,lang); - if(!res) { - snprintf(nextmsg,sizeof(nextmsg), "digits/h-%d", tm.tm_mday % 10); - res = wait_file(chan,ints,nextmsg,lang); - } - } + /* 1 - 31 'day' */ + res = ast_say_number_full_tw(chan, tm.tm_mday, ints, lang, -1, -1); + if (!res) + res = wait_file(chan, ints, "digits/day", lang); break; case 'Y': /* Year */