Fixed crash in GtkLockButton if a button with permission set to NULL is clicked.
https://bugzilla.gnome.org/show_bug.cgi?id=728992
This commit is contained in:

committed by
Matthias Clasen

parent
063bd57873
commit
f2d488dea1
@ -451,8 +451,10 @@ gtk_lock_button_clicked (GtkButton *button)
|
|||||||
{
|
{
|
||||||
GtkLockButtonPrivate *priv = GTK_LOCK_BUTTON (button)->priv;
|
GtkLockButtonPrivate *priv = GTK_LOCK_BUTTON (button)->priv;
|
||||||
|
|
||||||
/* if we already have a pending interactive check, then do nothing */
|
/* if we already have a pending interactive check or permission is not set,
|
||||||
if (priv->cancellable != NULL)
|
* then do nothing
|
||||||
|
*/
|
||||||
|
if (priv->cancellable != NULL || priv->permission == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (g_permission_get_allowed (priv->permission))
|
if (g_permission_get_allowed (priv->permission))
|
||||||
|
Reference in New Issue
Block a user