After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 684315 - More GDM /var initialization cleanup
More GDM /var initialization cleanup
Status: RESOLVED FIXED
Product: gdm
Classification: Core
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: GDM maintainers
GDM maintainers
Depends on:
Blocks:
 
 
Reported: 2012-09-18 18:33 UTC by Colin Walters
Modified: 2012-10-16 00:55 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
daemon: Clean up error handling for gdm_server_spawn() (5.38 KB, patch)
2012-09-18 18:33 UTC, Colin Walters
none Details | Review
server: Ensure log/auth directories exist at startup (7.09 KB, patch)
2012-09-18 18:33 UTC, Colin Walters
none Details | Review

Description Colin Walters 2012-09-18 18:33:07 UTC
I'd like this to go in for 3.7, but is it OK if I push a wip/ostree
git branch?
Comment 1 Colin Walters 2012-09-18 18:33:09 UTC
Created attachment 224657 [details] [review]
daemon: Clean up error handling for gdm_server_spawn()

This fixes a bug where we'd try to call g_child_watch_add() on a 0
pid in case of error.  More importantly, this moves us closer to
a sane error handling story where the default is to throw.
Comment 2 Colin Walters 2012-09-18 18:33:12 UTC
Created attachment 224658 [details] [review]
server: Ensure log/auth directories exist at startup

The daemon startup had lots of swapping around of effective uid, and
aborted if the log/auth directories didn't have the expected permissions.

Honestly this makes no sense - we're uid 0, so let's just ensure
they're directories and call chown() ourself.  I have no idea what the
"paranoia" here is about - if someone had managed to e.g. make a
symbolic link in /var to somewhere unexpected, there are plenty of
other ways they could attack the system.

Rather than aborting, let's just call mkdir()/chown()/chmod() and
check the return values.
Comment 3 Ray Strode [halfline] 2012-09-18 19:56:35 UTC
never have to ask permission to push a wip branch