[gtk/wip/otte/warnings: 5/6] Add missing G_GNUC_FALLTHROUGH statements



commit 8e8fdc5d63374aab27f5d5f11d80c060c6db7c5d
Author: Benjamin Otte <otte redhat com>
Date:   Sat Jan 26 15:09:33 2019 +0100

    Add missing G_GNUC_FALLTHROUGH statements

 gtk/gtkcssarrayvalue.c      | 1 +
 gtk/gtkcssdimensionvalue.c  | 1 +
 gtk/gtkcssnodedeclaration.c | 3 +++
 gtk/gtkmain.c               | 2 ++
 4 files changed, 7 insertions(+)
---
diff --git a/gtk/gtkcssarrayvalue.c b/gtk/gtkcssarrayvalue.c
index d294d90892..199f543600 100644
--- a/gtk/gtkcssarrayvalue.c
+++ b/gtk/gtkcssarrayvalue.c
@@ -289,6 +289,7 @@ gtk_css_value_array_transition (GtkCssValue *start,
        * into arrays and start animating them. */
       g_warning ("Don't know how to transition arrays for property '%s'", 
                  _gtk_style_property_get_name (GTK_STYLE_PROPERTY (_gtk_css_style_property_lookup_by_id 
(property_id))));
+      return NULL;
     case GTK_CSS_PROPERTY_TRANSITION_PROPERTY:
     case GTK_CSS_PROPERTY_TRANSITION_DURATION:
     case GTK_CSS_PROPERTY_TRANSITION_TIMING_FUNCTION:
diff --git a/gtk/gtkcssdimensionvalue.c b/gtk/gtkcssdimensionvalue.c
index 2920506e2c..851f597c83 100644
--- a/gtk/gtkcssdimensionvalue.c
+++ b/gtk/gtkcssdimensionvalue.c
@@ -111,6 +111,7 @@ gtk_css_value_dimension_compute (GtkCssValue      *number,
         return gtk_css_dimension_value_new (number->value / 100.0 * 
                                             get_base_font_size_px (property_id, provider, style, 
parent_style),
                                             GTK_CSS_PX);
+      G_GNUC_FALLTHROUGH;
     case GTK_CSS_NUMBER:
     case GTK_CSS_PX:
     case GTK_CSS_DEG:
diff --git a/gtk/gtkcssnodedeclaration.c b/gtk/gtkcssnodedeclaration.c
index 10b5458b02..6fb7422ae4 100644
--- a/gtk/gtkcssnodedeclaration.c
+++ b/gtk/gtkcssnodedeclaration.c
@@ -316,14 +316,17 @@ gtk_css_node_declaration_has_class (const GtkCssNodeDeclaration *decl,
     case 3:
       if (classes[2] == class_quark)
         return TRUE;
+      G_GNUC_FALLTHROUGH;
 
     case 2:
       if (classes[1] == class_quark)
         return TRUE;
+      G_GNUC_FALLTHROUGH;
 
     case 1:
       if (classes[0] == class_quark)
         return TRUE;
+      G_GNUC_FALLTHROUGH;
 
     case 0:
       return FALSE;
diff --git a/gtk/gtkmain.c b/gtk/gtkmain.c
index 6e83c49ba8..edfce6d0cd 100644
--- a/gtk/gtkmain.c
+++ b/gtk/gtkmain.c
@@ -1582,6 +1582,7 @@ handle_pointing_event (GdkEvent *event)
       if (event->crossing.mode == GDK_CROSSING_GRAB ||
           event->crossing.mode == GDK_CROSSING_UNGRAB)
         break;
+      G_GNUC_FALLTHROUGH;
     case GDK_TOUCH_END:
     case GDK_TOUCH_CANCEL:
       old_target = update_pointer_focus_state (toplevel, event, NULL);
@@ -1594,6 +1595,7 @@ handle_pointing_event (GdkEvent *event)
       if (event->crossing.mode == GDK_CROSSING_GRAB ||
           event->crossing.mode == GDK_CROSSING_UNGRAB)
         break;
+      G_GNUC_FALLTHROUGH;
     case GDK_TOUCH_BEGIN:
     case GDK_TOUCH_UPDATE:
     case GDK_MOTION_NOTIFY:


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