Fix crashing and compatibility with gnome-screensaver's D-Bus interface