]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
remove useless if, cleanup for grouchy compiler
authorAnthony Minessale <anthony.minessale@gmail.com>
Thu, 20 Sep 2007 18:05:01 +0000 (18:05 +0000)
committerAnthony Minessale <anthony.minessale@gmail.com>
Thu, 20 Sep 2007 18:05:01 +0000 (18:05 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5726 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/say/mod_say_en/mod_say_en.c

index 522dcb014d3f8a94b937b7b0bcf719ab995bdc23..f8a3ccfcf90f7474eae7c736e1800f7d46d29900 100644 (file)
@@ -175,8 +175,8 @@ static switch_status_t en_say_general_count(switch_core_session_t *session,
        if (in != 0) {
                for (x = 8; x >= 0; x--) {
                        int num = (int) pow(10, x);
-                       if ((places[x] = in / num)) {
-                               in -= places[x] * num;
+                       if ((places[(uint32_t)x] = in / num)) {
+                               in -= places[(uint32_t)x] * num;
                        }
                }
 
@@ -197,9 +197,7 @@ static switch_status_t en_say_general_count(switch_core_session_t *session,
                        {
                                char *p;
                                for (p = tosay; p && *p; p++) {
-                                       if (places[x] > -1) {
-                                               say_file("digits/%c.wav", *p);
-                                       }
+                                       say_file("digits/%c.wav", *p);
                                }
                        }
                        break;