[gtk+] Prevent a segfault if GtkAppChooserDialog gets disposed early
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] Prevent a segfault if GtkAppChooserDialog gets disposed early
- Date: Fri, 3 May 2013 01:36:52 +0000 (UTC)
commit 1afca5510a9db4f7b4cb6a844b237f072b209b08
Author: Matthias Clasen <mclasen redhat com>
Date: Thu May 2 20:00:49 2013 -0400
Prevent a segfault if GtkAppChooserDialog gets disposed early
If the async call is finished after the dialog is already disposed,
bad things happen. Prevent that by marking the dialog as dismissed
in this case.
gtk/gtkappchooserdialog.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkappchooserdialog.c b/gtk/gtkappchooserdialog.c
index e55eac3..ce7cfee 100644
--- a/gtk/gtkappchooserdialog.c
+++ b/gtk/gtkappchooserdialog.c
@@ -536,6 +536,8 @@ gtk_app_chooser_dialog_dispose (GObject *object)
cancel_and_clear_cancellable (self);
g_clear_object (&self->priv->online);
+ self->priv->dismissed = TRUE;
+
G_OBJECT_CLASS (gtk_app_chooser_dialog_parent_class)->dispose (object);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]