[gtk+] Avoid a dereference-before-null-check
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] Avoid a dereference-before-null-check
- Date: Wed, 15 Jun 2011 03:22:22 +0000 (UTC)
commit 32f0761daa7c86794d9b387f41cec42cbe02ab52
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Jun 14 21:50:16 2011 -0400
Avoid a dereference-before-null-check
gtk/gtktoolbar.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/gtk/gtktoolbar.c b/gtk/gtktoolbar.c
index 2515d3c..f654919 100644
--- a/gtk/gtktoolbar.c
+++ b/gtk/gtktoolbar.c
@@ -3669,7 +3669,6 @@ _gtk_toolbar_paint_space_line (GtkWidget *widget,
GtkToolbar *toolbar,
cairo_t *cr)
{
- GtkToolbarPrivate *priv = toolbar->priv;
GtkOrientation orientation;
GtkStyleContext *context;
GtkStateFlags state;
@@ -3680,7 +3679,7 @@ _gtk_toolbar_paint_space_line (GtkWidget *widget,
g_return_if_fail (GTK_IS_WIDGET (widget));
- orientation = toolbar ? priv->orientation : GTK_ORIENTATION_HORIZONTAL;
+ orientation = toolbar ? toolbar->priv->orientation : GTK_ORIENTATION_HORIZONTAL;
context = gtk_widget_get_style_context (widget);
state = gtk_widget_get_state_flags (widget);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]