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 706858 - Fix up get/set_property vfuncs for GDBus
Fix up get/set_property vfuncs for GDBus
Status: RESOLVED FIXED
Product: gnome-settings-daemon
Classification: Core
Component: power
unspecified
Other All
: Normal normal
: ---
Assigned To: gnome-settings-daemon-maint
gnome-settings-daemon-maint
Depends on:
Blocks:
 
 
Reported: 2013-08-27 00:33 UTC by Matthias Clasen
Modified: 2013-08-27 11:38 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix up get/set_property vfuncs for GDBus (6.29 KB, patch)
2013-08-27 00:33 UTC, Matthias Clasen
committed Details | Review
Fix up get/set_property vfuncs for GDBus (6.45 KB, patch)
2013-08-27 11:30 UTC, Matthias Clasen
committed Details | Review

Description Matthias Clasen 2013-08-27 00:33:44 UTC
GDBus asserts that a get_property implementation sets an error
if it returns NULL, and that a set_property implementation sets
and error if it returns FALSE. The power plugin was very far
from this requirement, and I have seen crashes of
gnome-settings-daemon due to this, when trying to set screen
brightness in a VM.
Comment 1 Matthias Clasen 2013-08-27 00:33:46 UTC
Created attachment 253211 [details] [review]
Fix up get/set_property vfuncs for GDBus
Comment 2 Jasper St. Pierre (not reading bugmail) 2013-08-27 00:44:43 UTC
Review of attachment 253211 [details] [review]:

::: plugins/power/gsd-power-manager.c
@@ +3829,2 @@
         } else {
                 g_warning ("not recognised interface: %s", interface_name);

You forgot this one.
Comment 3 Matthias Clasen 2013-08-27 11:30:55 UTC
Created attachment 253236 [details] [review]
Fix up get/set_property vfuncs for GDBus

GDBus asserts that a get_property implementation sets an error
if it returns NULL, and that a set_property implementation sets
and error if it returns FALSE. The power plugin was very far
from this requirement, and I have seen crashes of
gnome-settings-daemon due to this, when trying to set screen
brightness in a VM.
Comment 4 Richard Hughes 2013-08-27 11:31:50 UTC
Agreed, colord had the same bug a few months ago. With Jaspers fix, looks good for me. Thanks.
Comment 5 Matthias Clasen 2013-08-27 11:37:55 UTC
Attachment 253211 [details] pushed as a8917af - Fix up get/set_property vfuncs for GDBus
Attachment 253236 [details] pushed as a8917af - Fix up get/set_property vfuncs for GDBus