[gnome-commander] src/gnome-cmd-main-win.cc: fix for -Wimplicit-fallthrough



commit a9c4b995df807f047f2412bd12a7887f3eb3c0c9
Author: Mamoru TASAKA <mtasaka fedoraproject org>
Date:   Mon Apr 24 13:07:56 2017 +0900

    src/gnome-cmd-main-win.cc: fix for -Wimplicit-fallthrough
    
    src/gnome-cmd-main-win.cc:690:77: error: this statement may fall through [-Werror=implicit-fallthrough=]
                 if (gnome_cmd_data.main_win_state == GDK_WINDOW_STATE_MAXIMIZED ||  // prev state
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
                     gnome_cmd_data.main_win_state == GDK_WINDOW_STATE_FULLSCREEN)
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

 src/gnome-cmd-main-win.cc |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/gnome-cmd-main-win.cc b/src/gnome-cmd-main-win.cc
index b090d1f..2fd508a 100644
--- a/src/gnome-cmd-main-win.cc
+++ b/src/gnome-cmd-main-win.cc
@@ -691,6 +691,9 @@ static gboolean on_window_state_event (GtkWidget *mw, GdkEventWindowState *event
                 gnome_cmd_data.main_win_state == GDK_WINDOW_STATE_FULLSCREEN)
                 break;  // not usable
 
+#if defined (__GNUC__) && __GNUC__ >= 7
+        __attribute__ ((fallthrough));
+#endif
         default:            // other are usable
             gdk_window_get_root_origin (mw->window, &x, &y);
             gnome_cmd_data_set_main_win_pos (x, y);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]