GNOME Bugzilla – Bug 727549
dconf-service hangs shutdown
Last modified: 2014-04-04 14:23:11 UTC
Created attachment 273537 [details] [review] Don't hang during shutdown dconf-service refuses to quit when it receives SIGTERM followed by SIGHUP. This can happen during shutdown. Steps to reproduce are: 1) log as an user to Gnome session 2) switch to another user by using the "Switch User" menu item 3) poweroff the system by using the "Power Off" menu item 4) wait It doesn't hang everytime (it hangs for me 2-3x during 5 attempts). You can see that the component which hangs the shutdown is dconf by turning the systemd's debugging on and looking at the log (see http://freedesktop.org/wiki/Software/systemd/Debugging/#index2h1). This happens because dconf-service calls g_application_release() twice (because of the SIGTERM and SIGHUP) but it called g_application_hold() just once before. The attached patch fixes this for me. I'll file a bug for Glib to add an assert to the g_application_release(). Regards Marek
Review of attachment 273537 [details] [review]: Nice catch. Please feel free to commit after the trivial fix. ::: service/dconf-service.c @@ +41,3 @@ GArray *subtree_ids; + + gboolean signalized; Can you rename this to something more reasonable, like "released" or "exiting"?
Comment on attachment 273537 [details] [review] Don't hang during shutdown (In reply to comment #1) > Review of attachment 273537 [details] [review]: > > Nice catch. Please feel free to commit after the trivial fix. > > ::: service/dconf-service.c > @@ +41,3 @@ > GArray *subtree_ids; > + > + gboolean signalized; > > Can you rename this to something more reasonable, like "released" or "exiting"? Thank you for the review. I used "released" for the name of the variable. I've pushed the patch to master. Do you want me to push it also to a stable branch? Marek
Yes please.
Thank you. I've pushed it to dconf-0-18.