[anjuta] git: use g_signal_connect_object() in GitLogCommand
- From: Carl-Anton Ingmarsson <carlantoni src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [anjuta] git: use g_signal_connect_object() in GitLogCommand
- Date: Tue, 19 Feb 2013 22:59:01 +0000 (UTC)
commit 275d5efe25f2e8ca6c22109c6422e31a90abeb0a
Author: Carl-Anton Ingmarsson <ca ingmarsson gmail com>
Date: Tue Feb 19 09:08:34 2013 +0100
git: use g_signal_connect_object() in GitLogCommand
Use g_signal_connect_object() in GitLogCommand to connect to the signals
on GitLogDataCommand. This way the signals will be disconnected when
GitLogCommand is disposed. The signals need to be disconnected since
the GitLogDataCommand may not be finalized when GitLogCommand releases
its reference to it.
https://bugzilla.gnome.org/show_bug.cgi?id=694194
plugins/git/git-log-command.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/plugins/git/git-log-command.c b/plugins/git/git-log-command.c
index c937940..60759d4 100644
--- a/plugins/git/git-log-command.c
+++ b/plugins/git/git-log-command.c
@@ -64,13 +64,13 @@ git_log_command_init (GitLogCommand *self)
self->priv->data_command = git_log_data_command_new ();
- g_signal_connect (G_OBJECT (self->priv->data_command), "data-arrived",
- G_CALLBACK (on_data_command_data_arrived),
- self);
+ g_signal_connect_object (G_OBJECT (self->priv->data_command), "data-arrived",
+ G_CALLBACK (on_data_command_data_arrived),
+ self, 0);
- g_signal_connect (G_OBJECT (self->priv->data_command), "command-finished",
- G_CALLBACK (on_data_command_finished),
- self);
+ g_signal_connect_object (G_OBJECT (self->priv->data_command), "command-finished",
+ G_CALLBACK (on_data_command_finished),
+ self, 0);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]