Merge lp:~serge-hallyn/ubuntu/precise/util-linux/fix-getty-on-pts into lp:ubuntu/precise/util-linux

Proposed by Serge Hallyn
Status: Merged
Merged at revision: 86
Proposed branch: lp:~serge-hallyn/ubuntu/precise/util-linux/fix-getty-on-pts
Merge into: lp:ubuntu/precise/util-linux
Diff against target: 49 lines (+14/-3)
2 files modified
debian/changelog (+11/-0)
term-utils/agetty.c (+3/-3)
To merge this branch: bzr merge lp:~serge-hallyn/ubuntu/precise/util-linux/fix-getty-on-pts
Reviewer Review Type Date Requested Status
Colin Watson Approve
Review via email: mp+88438@code.launchpad.net

Description of the change

patch term-utils/agetty.c: allow getty to work on /dev/pts/N

This takes upstream commit 1593b134ebf596ae7a2b1e73f2dcc8c4e7febddd,
plus an extra s/log_err/log_warn/ if when tcsetpgrp fails.

This is needed for libvirt-lxc and lxc consoles to work.

To post a comment you must log in.
Revision history for this message
Colin Watson (cjwatson) wrote :

Looks good to me, thanks.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/changelog'
--- debian/changelog 2011-12-16 22:53:42 +0000
+++ debian/changelog 2012-01-12 23:06:03 +0000
@@ -1,3 +1,14 @@
1util-linux (2.20.1-1ubuntu2) precise; urgency=low
2
3 * term-utils/agetty.c: allow getty to work on /dev/pts/N
4
5 This takes upstream commit 1593b134ebf596ae7a2b1e73f2dcc8c4e7febddd,
6 plus an extra s/log_err/log_warn/ if when tcsetpgrp fails.
7
8 This is needed for libvirt-lxc and lxc consoles to work.
9
10 -- Serge Hallyn <serge.hallyn@ubuntu.com> Thu, 12 Jan 2012 13:54:09 +0100
11
1util-linux (2.20.1-1ubuntu1) precise; urgency=low12util-linux (2.20.1-1ubuntu1) precise; urgency=low
213
3 * Merge from Debian unstable, remaining changes:14 * Merge from Debian unstable, remaining changes:
415
=== modified file 'term-utils/agetty.c'
--- term-utils/agetty.c 2011-11-03 15:38:23 +0000
+++ term-utils/agetty.c 2012-01-12 23:06:03 +0000
@@ -908,7 +908,7 @@
908908
909 if (((tid = tcgetsid(fd)) < 0) || (pid != tid)) {909 if (((tid = tcgetsid(fd)) < 0) || (pid != tid)) {
910 if (ioctl(fd, TIOCSCTTY, 1) == -1)910 if (ioctl(fd, TIOCSCTTY, 1) == -1)
911 log_err("/dev/%s: cannot get controlling tty: %m", tty);911 log_warn("/dev/%s: cannot get controlling tty: %m", tty);
912 }912 }
913913
914 if (op->flags & F_HANGUP) {914 if (op->flags & F_HANGUP) {
@@ -933,7 +933,7 @@
933 log_err(_("/dev/%s: cannot open as standard input: %m"), tty);933 log_err(_("/dev/%s: cannot open as standard input: %m"), tty);
934 if (((tid = tcgetsid(STDIN_FILENO)) < 0) || (pid != tid)) {934 if (((tid = tcgetsid(STDIN_FILENO)) < 0) || (pid != tid)) {
935 if (ioctl(STDIN_FILENO, TIOCSCTTY, 1) == -1)935 if (ioctl(STDIN_FILENO, TIOCSCTTY, 1) == -1)
936 log_err("/dev/%s: cannot get controlling tty: %m", tty);936 log_warn("/dev/%s: cannot get controlling tty: %m", tty);
937 }937 }
938938
939 } else {939 } else {
@@ -949,7 +949,7 @@
949 }949 }
950950
951 if (tcsetpgrp(STDIN_FILENO, pid))951 if (tcsetpgrp(STDIN_FILENO, pid))
952 log_err("/dev/%s: cannot set process group: %m", tty);952 log_warn("/dev/%s: cannot set process group: %m", tty);
953953
954 /* Get rid of the present outputs. */954 /* Get rid of the present outputs. */
955 close(STDOUT_FILENO);955 close(STDOUT_FILENO);

Subscribers

People subscribed via source and target branches

to all changes: