[gtk+] widget: Initialize a local variable



commit cc9a4c17207e7bab3c09d608dc65ea8d445bc7e5
Author: Timm Bäder <mail baedert org>
Date:   Thu Jan 18 14:42:39 2018 +0100

    widget: Initialize a local variable
    
    We will later pass this variable on to some other functions, so be safe
    against them using the value.

 gtk/gtkwidget.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index 2f12199..46ad980 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -4513,7 +4513,7 @@ gtk_widget_size_allocate (GtkWidget           *widget,
   gboolean size_changed;
   gboolean baseline_changed;
   gboolean position_changed;
-  gint natural_width, natural_height, dummy;
+  gint natural_width, natural_height, dummy = 0;
   gint min_width, min_height;
   GtkCssStyle *style;
   GtkBorder margin, border, padding;


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