summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Catanzaro <mcatanzaro@gnome.org>2022-10-27 14:45:07 +0000
committerMichael Catanzaro <mcatanzaro@gnome.org>2022-10-27 14:45:07 +0000
commit07acae0773116c62dc9794394f020305cc4159b8 (patch)
tree839ac125c109c24545d235b7bf4d8814e406e0fd
parentda05c822a018ec41cd22a11b2dabb9b72251d91d (diff)
parente30df2e435bbb5c9a1314b09d505a2df4230db51 (diff)
downloadgnome-online-accounts-07acae0773116c62dc9794394f020305cc4159b8.tar.gz
Merge branch 'fix-dropped-notify' into 'master'
kerberos-identity: Ensure idles queued to main thread are property synchronized Closes #160 See merge request GNOME/gnome-online-accounts!108
-rw-r--r--src/goaidentity/goakerberosidentity.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/goaidentity/goakerberosidentity.c b/src/goaidentity/goakerberosidentity.c
index b72ce6a..8eb6ba2 100644
--- a/src/goaidentity/goakerberosidentity.c
+++ b/src/goaidentity/goakerberosidentity.c
@@ -520,7 +520,10 @@ typedef struct
static void
clear_idle_id (NotifyRequest *request)
{
+ G_LOCK (identity_lock);
*request->idle_id = 0;
+ G_UNLOCK (identity_lock);
+
g_object_unref (request->self);
g_slice_free (NotifyRequest, request);
}
@@ -540,8 +543,10 @@ queue_notify (GoaKerberosIdentity *self,
{
NotifyRequest *request;
+ G_LOCK (identity_lock);
if (*idle_id != 0)
{
+ G_UNLOCK (identity_lock);
return;
}
@@ -556,6 +561,7 @@ queue_notify (GoaKerberosIdentity *self,
request,
(GDestroyNotify)
clear_idle_id);
+ G_UNLOCK (identity_lock);
}
static gboolean