Fix implicit fallthrough warnings
authorAndre Heinecke <aheinecke@gnupg.org>
Mon, 11 Feb 2019 13:35:52 +0000 (14:35 +0100)
committerAndre Heinecke <aheinecke@gnupg.org>
Mon, 11 Feb 2019 13:35:52 +0000 (14:35 +0100)
* src/application-events.cpp: Fix unintentional fallthrough from
QUIT.
* src/mailitem-events.cpp: Mark reply fallthrough as intentional.

src/application-events.cpp
src/mailitem-events.cpp

index 5d8b9a8..06baaf7 100644 (file)
@@ -100,6 +100,7 @@ EVENT_SINK_INVOKE(ApplicationEvents)
         {
           log_debug ("%s:%s: Quit event. Shutting down",
                      SRCNAME, __func__);
+          TBREAK;
         }
       default:
         log_oom ("%s:%s: Unhandled Event: %lx \n",
index b251229..fa12d88 100644 (file)
@@ -762,9 +762,8 @@ EVENT_SINK_INVOKE(MailItemEvents)
       /* Fallthrough */
       case ReplyAll:
       case Reply:
-        {
           is_reply = true;
-        }
+          __attribute__ ((fallthrough));
       case Forward:
         {
           log_oom ("%s:%s: %s : %p",