[asterisk-commits] file: branch 1.4 r45051 - /branches/1.4/apps/app_playback.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Fri Oct 13 09:20:58 MST 2006


Author: file
Date: Fri Oct 13 11:20:58 2006
New Revision: 45051

URL: http://svn.digium.com/view/asterisk?rev=45051&view=rev
Log:
Move say.conf existence check to do_say function since it is called from multiple places (issue #8144 reported by kshumard)

Modified:
    branches/1.4/apps/app_playback.c

Modified: branches/1.4/apps/app_playback.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/apps/app_playback.c?rev=45051&r1=45050&r2=45051&view=diff
==============================================================================
--- branches/1.4/apps/app_playback.c (original)
+++ branches/1.4/apps/app_playback.c Fri Oct 13 11:20:58 2006
@@ -155,6 +155,9 @@
 	ast_log(LOG_WARNING, "string <%s> depth <%d>\n", s, depth);
 	if (depth++ > 10) {
 		ast_log(LOG_WARNING, "recursion too deep, exiting\n");
+		return -1;
+	} else if (!say_cfg) {
+		ast_log(LOG_WARNING, "no say.conf, cannot spell '%s'\n", s);
 		return -1;
 	}
 
@@ -253,11 +256,6 @@
         int audiofd, int ctrlfd)
 {
         say_args_t a = { chan, ints, lang, audiofd, ctrlfd };
-  
-        if (!say_cfg) {
-                ast_log(LOG_WARNING, "no say.conf, cannot spell '%s'\n", string);
-                return -1;   
-        }
         return do_say(&a, string, options, 0);
 }
 



More information about the asterisk-commits mailing list