[gitg] Avoid disconnecting signal during handlers destroy
- From: Jesse van den Kieboom <jessevdk src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gitg] Avoid disconnecting signal during handlers destroy
- Date: Thu, 31 Dec 2015 00:31:03 +0000 (UTC)
commit 67e5877849a4808b0436717f94caba42a755c4ac
Author: Jesse van den Kieboom <jessevdk gnome org>
Date: Thu Dec 31 01:26:29 2015 +0100
Avoid disconnecting signal during handlers destroy
libgitg/gitg-when-mapped.vala | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/libgitg/gitg-when-mapped.vala b/libgitg/gitg-when-mapped.vala
index 4142ab2..03b3071 100644
--- a/libgitg/gitg-when-mapped.vala
+++ b/libgitg/gitg-when-mapped.vala
@@ -38,6 +38,7 @@ namespace Gitg
private void weak_notify(Object o)
{
d_widget = null;
+ d_sid = 0;
if (d_lifetime != null)
{
@@ -50,7 +51,7 @@ namespace Gitg
{
if (d_widget != null)
{
- if (d_sid != 0)
+ if (d_sid != 0 && SignalHandler.is_connected(d_widget, d_sid))
{
d_widget.disconnect(d_sid);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]