[gtk+/gtk-3-12] Fixed crash in GtkLockButton if a button with permission set to NULL is clicked.
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-3-12] Fixed crash in GtkLockButton if a button with permission set to NULL is clicked.
- Date: Sat, 26 Apr 2014 02:21:22 +0000 (UTC)
commit 539f18f998763308a4798d68320c8124f0b9824b
Author: Juan Pablo Ugarte <juanpablougarte gmail com>
Date: Fri Apr 25 19:18:28 2014 -0300
Fixed crash in GtkLockButton if a button with permission set to NULL is clicked.
https://bugzilla.gnome.org/show_bug.cgi?id=728992
gtk/gtklockbutton.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/gtk/gtklockbutton.c b/gtk/gtklockbutton.c
index 6b051d1..d0c973b 100644
--- a/gtk/gtklockbutton.c
+++ b/gtk/gtklockbutton.c
@@ -451,8 +451,10 @@ gtk_lock_button_clicked (GtkButton *button)
{
GtkLockButtonPrivate *priv = GTK_LOCK_BUTTON (button)->priv;
- /* if we already have a pending interactive check, then do nothing */
- if (priv->cancellable != NULL)
+ /* if we already have a pending interactive check or permission is not set,
+ * then do nothing
+ */
+ if (priv->cancellable != NULL || priv->permission == NULL)
return;
if (g_permission_get_allowed (priv->permission))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]