[glade/gbinding] Add forgotten NULL check to glade_binding_set_source()
- From: Denis Washington <denisw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glade/gbinding] Add forgotten NULL check to glade_binding_set_source()
- Date: Fri, 10 Jun 2011 12:54:16 +0000 (UTC)
commit 51824a0410023950e40512b1525a5446bc886447
Author: Denis Washington <denisw src gnome org>
Date: Fri Jun 10 14:36:29 2011 +0200
Add forgotten NULL check to glade_binding_set_source()
gladeui/glade-binding.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gladeui/glade-binding.c b/gladeui/glade-binding.c
index 2f4fb16..8398ef9 100644
--- a/gladeui/glade-binding.c
+++ b/gladeui/glade-binding.c
@@ -242,11 +242,11 @@ glade_binding_set_source (GladeBinding *binding,
if (priv->source)
g_object_remove_weak_pointer (G_OBJECT (priv->source),
(gpointer *) &priv->source);
+ if (source)
+ g_object_add_weak_pointer (G_OBJECT (source),
+ (gpointer *) &priv->source);
priv->source = source;
- g_object_add_weak_pointer (G_OBJECT (priv->source),
- (gpointer *) &priv->source);
-
glade_binding_update (binding);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]