Hi, I run OpenBSD -current amd64. I upgraded to xfce 4.12 and then xfsettingsd segfaulted. The trace was: #0 0x00001959bf357ccd in up_client_glue_get_lid_is_closed () from /usr/local/lib/libupower-glib.so.1.0 If I run upower -d I had (upower:13761): libupower-glib-WARNING **: Couldn't connect to proxy: Impossible de se connecter : No such file or directory (upower:13761): GLib-GIO-CRITICAL **: g_dbus_proxy_call_sync_internal: assertion 'G_IS_DBUS_PROXY (proxy)' failed Segmentation fault (core dumped) (sorry for the mix of French message and UTF-8 garbage) I only had /usr/local/bin/dbus-daemon --fork --print-pid 5 --print-address 7 --session and /usr/local/bin/dbus-launch --sh-syntax --exit-with-session xfce4-session running. Then I run sudo /etc/rc.d/dbus_daemon start && upower -d and it works, so I added to /etc/rc.conf.local dbus_daemon_flags= pkg_scripts="dbus_daemon" and after rebooting xfsettingsd worked correctly. Of course, all of this was found thanks to Landry :)
So what this means is xfsettingsd or upower-glib doesnt handle well a missing upowerd running.. would be nice to have the full trace to see which xfsettingsd function calls upower, and if it should check first for upower presence on the dbus.
Only calls are in http://git.xfce.org/xfce/xfce4-settings/tree/xfsettingsd/displays-upower.c#n103 and http://git.xfce.org/xfce/xfce4-settings/tree/xfsettingsd/displays-upower.c#n153. Maybe should check for client object validity before using it ? Or maybe that's specific to the openbsd backend in upower which doesnt handle well some fallback codepaths and up_client crashing on it..
Created attachment 6764 0001-Fix-segfault-when-upowerd-is-not-running.patch Attached patch should fix this issue. Note that it is relies on changes (/?id=932a6a39e35754be571e1274aec4730fd42dba13) in the upower > 0.99.4, which is not released yet.
(In reply to Mikhail Efremov from comment #3) > (/?id=932a6a39e35754be571e1274aec4730fd42dba13) Wrong url, sorry. The right one is https://cgit.freedesktop.org/upower/commit/?id=932a6a39e35754be571e1274aec4730fd42dba13
I've tested the patch in comment 3 (along the upower patch) and it indeed does the right thing. Sean, what do you think about it ?
-- GitLab Migration Automatic Message -- This bug has been migrated to xfce.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.xfce.org/xfce/xfce4-settings/-/issues/60. Please create an account or use an existing account on one of our supported OAuth providers. If you want to fork to submit patches and merge requests please continue reading here: https://docs.xfce.org/contribute/dev/git/start#gitlab_forks_and_merge_requests Also feel free to reach out to us on the mailing list https://mail.xfce.org/mailman/listinfo/xfce4-dev