Merge lp:~lotheac/lightdm/utmpx into lp:lightdm
Proposed by
Lauri Tirkkonen
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 1508 | ||||
Proposed branch: | lp:~lotheac/lightdm/utmpx | ||||
Merge into: | lp:lightdm | ||||
Diff against target: |
98 lines (+42/-8) 1 file modified
src/session-child.c (+42/-8) |
||||
To merge this branch: | bzr merge lp:~lotheac/lightdm/utmpx | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
LightDM Development Team | Pending | ||
Robert Ancell | Pending | ||
Review via email: mp+107739@code.launchpad.net |
This proposal supersedes a proposal from 2012-05-23.
Description of the change
Write utmpx records for user sessions. This fixes bug #870297 in Ubuntu.
To post a comment you must log in.
Hi, thanks for that!
40 + is_greeter = (class && 0 == strncmp(class, XDG_SESSION_ CLASS_GREETER, CLASS_GREETER) ); CLASS_GREETER) == 0;
41 + sizeof XDG_SESSION_
This can be more simply done with:
is_greeter = g_strcmp0 (class, XDG_SESSION_
58 + if (!is_greeter) {
59 + /* Open the session */
60 + result = pam_open_session (pam_handle, 0);
You should still open a PAM session for the greeter, why not?
73 - /* Wait for the command to complete (blocks) */
You seem to have accidentally removed a comment :(
76 + if (!is_greeter) {
Braces start on a new line
86 + if (remote_host_name) {
87 + strncpy (ut.ut_host, remote_host_name, sizeof (ut.ut_host));
88 + } else {
89 + memset (ut.ut_host, 0, sizeof (ut.ut_host));
90 + }
Don't need braces for single line branches