GNOME Bugzilla – Bug 721380
gsm-system: add a null backend
Last modified: 2014-01-03 14:35:43 UTC
Add a 'null' backend for gsm-system to deal with the case where we don't have systemd and our version of upower is too new. Without this fallback case, gnome-session segfaults on startup.
Created attachment 265204 [details] [review] gsm-system: add a null backend
This is fallout from bug 710383 (which allowed the build to proceed, but produced a gnome-session that crashed on startup in case systemd wasn't present, or wasn't running at gnome-session startup).
Review of attachment 265204 [details] [review]: The _get_property implementation seems likely to be a source of crashes if someone introduces a non-boolean property. But I don't really care that much, so fine by me. ::: gnome-session/gsm-system.c @@ +268,3 @@ + if (system == NULL) { + system = g_object_new (gsm_system_null_get_type (), NULL); + g_debug ("Using null backend for session tracking"); Maybe a g_warning()?
Attachment 265204 [details] pushed as bf3f892 - gsm-system: add a null backend