Update of /usr/cvsroot/asterisk
In directory mongoose.digium.com:/tmp/cvs-serv16916

Modified Files:
        say.c 
Log Message:
don't declare variables inside a code block (bug #4681)
fix formatting


Index: say.c
===================================================================
RCS file: /usr/cvsroot/asterisk/say.c,v
retrieving revision 1.65
retrieving revision 1.66
diff -u -d -r1.65 -r1.66
--- say.c       12 Jul 2005 03:00:49 -0000      1.65
+++ say.c       12 Jul 2005 14:58:25 -0000      1.66
@@ -3618,13 +3618,10 @@
                                /* Shorthand for "" (today), "Yesterday", A 
                                  * (weekday), or "date" */
                                {
-                                       char todo='q';/* The letter to format*/
-                                       if (format[offset] == 'Q') {
-                                               todo='Q';
-                                       }
                                        struct timeval now;
                                        struct tm tmnow;
                                        time_t beg_today;
+                                       char todo = format[offset]; /* The 
letter to format*/
 
                                        gettimeofday(&now,NULL);
                                        
ast_localtime(&now.tv_sec,&tmnow,timezone);
@@ -3635,9 +3632,9 @@
                                                /* Today */
                                                if (todo == 'Q') {
                                                        res = wait_file(chan,
-                                                               ints, 
-                                                               "digits/today",
-                                                               lang);
+                                                                       ints, 
+                                                                       
"digits/today",
+                                                                       lang);
                                                }
                                        } else if (beg_today - 86400 < time) {
                                                /* Yesterday */
@@ -3646,13 +3643,13 @@
                                                (beg_today - 86400 * 6 < time))
                                        {
                                                /* Within the last week */
-                                               res = 
ast_say_date_with_format_he(
-                                                       chan, time, ints, lang, 
-                                                       "A", timezone);
+                                               res = 
ast_say_date_with_format_he(chan,
+                                                                               
  time, ints, lang, 
+                                                                               
  "A", timezone);
                                        } else {
-                                               res = 
ast_say_date_with_format_he(
-                                                       chan, time, ints, lang, 
-                                                       IL_DATE_STR, timezone);
+                                               res = 
ast_say_date_with_format_he(chan,
+                                                                               
  time, ints, lang, 
+                                                                               
  IL_DATE_STR, timezone);
                                        }
                                }
                                break;

_______________________________________________
Asterisk-Cvs mailing list
[email protected]
http://lists.digium.com/mailman/listinfo/asterisk-cvs

Reply via email to