Bug 51511 - dbus-glib-0.100 fails testsuite
Summary: dbus-glib-0.100 fails testsuite
Status: RESOLVED FIXED
Alias: None
Product: dbus
Classification: Unclassified
Component: GLib (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Simon McVittie
QA Contact: John (J5) Palmieri
URL:
Whiteboard: review?
Keywords: patch
Depends on:
Blocks:
 
Reported: 2012-06-28 02:53 UTC by Michael
Modified: 2012-06-30 09:19 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
build log (51.60 KB, application/octet-stream)
2012-06-28 02:53 UTC, Michael
Details
my_object_unsafe_disable_legacy_property_access: have the right signature (1.65 KB, patch)
2012-06-28 04:56 UTC, Simon McVittie
Details | Splinter Review

Description Michael 2012-06-28 02:53:01 UTC
Created attachment 63556 [details]
build log

From our downstream bug report: https://bugs.gentoo.org/show_bug.cgi?id=356699

Attached is a fresh build log showing the error. I note that the following also appears in dmesg: lt-test-dbus-gl[10571] trap int3 ip:28f2d5e3561 sp:3f00534f7b0 error:0
Comment 1 Simon McVittie 2012-06-28 04:43:56 UTC
The error is:

** (process:10571): ERROR **: Failed to invoke UnsafeDisableLegacyPropertyAccess (org.freedesktop.DBus.GLib.ErrorError): Method invoked for UnsafeDisableLegacyPropertyAccess returned FALSE but did not set error

The offending function:

> void
> my_object_unsafe_disable_legacy_property_access (MyObject *obj)
> {
>   dbus_glib_global_set_disable_legacy_property_access ();
> }

has the wrong signature. It should return gboolean, and have a GError** as a second parameter.

The generated code expects it to return boolean:

  { (GCallback) my_object_unsafe_disable_legacy_property_access, dbus_glib_marshal_my_object_BOOLEAN__POINTER, 2486 },

The fact that the compiler cannot detect this is one of the many design flaws in dbus-glib.
Comment 2 Simon McVittie 2012-06-28 04:56:00 UTC
Created attachment 63561 [details] [review]
my_object_unsafe_disable_legacy_property_access: have the  right signature

I'm amazed this ever worked.

Bug: https://bugs.freedesktop.org/show_bug.cgi?id=51511
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>

---

This is a bug in the regression test, rather than in dbus-glib itself, but it's a symptom of dbus-glib's design flaws. Have I ever mentioned how much better-designed GDBus is?
Comment 3 Colin Walters 2012-06-28 07:52:33 UTC
Comment on attachment 63561 [details] [review]
my_object_unsafe_disable_legacy_property_access: have the  right signature

Review of attachment 63561 [details] [review]:
-----------------------------------------------------------------

Looks correct, thanks!
Comment 4 Simon McVittie 2012-06-28 09:07:53 UTC
Fixed in git for 0.102.
Comment 5 Michael 2012-06-30 09:19:56 UTC
Working well now, thank-you for the quick response!


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.