After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 740848 - Backend subscription fails when connecting to a signal with a detail
Backend subscription fails when connecting to a signal with a detail
Status: RESOLVED FIXED
Product: glib
Classification: Platform
Component: gsettings
unspecified
Other All
: Normal normal
: ---
Assigned To: Allison Karlitskaya (desrt)
gtkdev
Depends on:
Blocks:
 
 
Reported: 2014-11-28 12:15 UTC by Lars Karlitski
Modified: 2014-11-28 14:19 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
GSettings: fix check for delaying backend subscription (2.62 KB, patch)
2014-11-28 12:15 UTC, Lars Karlitski
committed Details | Review

Description Lars Karlitski 2014-11-28 12:15:43 UTC
See patch.
Comment 1 Lars Karlitski 2014-11-28 12:15:45 UTC
Created attachment 291717 [details] [review]
GSettings: fix check for delaying backend subscription

g_settings_has_signal_handlers() checks whether any of the signals has
pending handlers. However, g_signal_has_handler_pending() matches on
exact detail, even when passing 0. Subscribing to one of GSettings'
signals with a detail will fail this check and never connect to the
backend.

Fix this by calling has_handler_pending() with the key as detail as
well.
Comment 2 Allison Karlitskaya (desrt) 2014-11-28 14:11:52 UTC
Review of attachment 291717 [details] [review]:

Ugh.  I would have figured 0 was a wildcard.  I assume you tested this and it properly works the other way? :)

Nice idea for the fix in any case -- and I guess you know that this will be reverted soon.
Comment 3 Lars Karlitski 2014-11-28 14:19:48 UTC
Attachment 291717 [details] pushed as d511d6b - GSettings: fix check for delaying backend subscription