]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Address MISSING_BREAK static analysis reports some more.
authorMark Michelson <mmichelson@digium.com>
Fri, 18 May 2012 17:47:31 +0000 (17:47 +0000)
committerMark Michelson <mmichelson@digium.com>
Fri, 18 May 2012 17:47:31 +0000 (17:47 +0000)
This addresses core findings 4 and 6.

Moises Silva helped me by stating that a break could be
safely added to the case where it is added in chan_dahdi.c

In say.c, I have added a comment indicating that static analysis
complains but that it is currently unknown if this is correct.

This fixes all core findings of this type.

(closes issue ASTERISK-19662)
reported by Matthew Jordan

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@367027 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_dahdi.c
main/say.c

index 329d3b9c1a2434ab249c7f6e04b7c32e661e1782..f3a293397ed800dfc59e396cab439d88fa5b7cb1 100644 (file)
@@ -7966,6 +7966,7 @@ static struct ast_frame *dahdi_handle_event(struct ast_channel *ast)
 #else
                ast_log(LOG_WARNING, "Received bits changed on %s signalling?\n", sig2str(p->sig));
 #endif
+               break;
        case DAHDI_EVENT_PULSE_START:
                /* Stop tone if there's a pulse start and the PBX isn't started */
                if (!ast->pbx)
index e5225287485117b2748ec079ad2e801ac6a69af2..e1580a3c1198cff65c25a1c8ec87f04976ec6b35 100644 (file)
@@ -6113,6 +6113,9 @@ int ast_say_date_with_format_zh(struct ast_channel *chan, time_t t, const char *
                                if (tm.tm_hour < 10) {
                                        res = wait_file(chan, ints, "digits/0", lang);
                                }
+                               /* XXX Static analysis warns of no break here. No idea if this is
+                                * correct or not
+                                */
                        case 'k':
                                /* 24-Hour */
                                if (!(tm.tm_hour % 10) || tm.tm_hour < 10) {