util-linux/lib
Karel Zak 790119b885 agetty: fix characters reorder in login prompt
The current agetty uses TIOCSTI ioctl to return already read chars
from login name back to the terminal (without read() before
tcsetattr() we will lost data already written by user). The ioctl
based solution is fragile due to race -- we can return chars when
terminal already contains another new chars. The result is reordered
chars in login name.

The solution is to use extra buffer for already read data.

Reported-by: Michael Tretter <m.tretter@pengutronix.de>
Signed-off-by: Karel Zak <kzak@redhat.com>
2017-03-27 14:54:39 +02:00
..
.gitignore build-sys: add parse-date.y 2017-03-04 11:01:56 -05:00
Makemodule.am build-sys: add parse-date.y 2017-03-04 11:01:56 -05:00
blkdev.c lib: use unique ifdefs for tests 2017-01-04 11:44:37 +01:00
canonicalize.c misc: Fix various typos 2016-05-31 23:40:21 +02:00
color-names.c lib/color: add more ESC seq. 2016-02-17 12:51:15 +01:00
colors.c tests: do not use plain 0 as NULL [smatch scan] 2017-03-17 21:22:26 +00:00
cpuset.c tests: do not use plain 0 as NULL [smatch scan] 2017-03-17 21:22:26 +00:00
crc32.c lib/crc32: prefix public functions 2016-10-19 12:11:59 +02:00
env.c build-sys: test for secure_getenv() too. 2013-02-06 12:03:22 +01:00
exec_shell.c exec_shell: prevent basename from modifying env 2016-02-11 13:40:28 +01:00
fileutils.c lib: use unique ifdefs for tests 2017-01-04 11:44:37 +01:00
idcache.c agetty: fix characters reorder in login prompt 2017-03-27 14:54:39 +02:00
ismounted.c lib: use unique ifdefs for tests 2017-01-04 11:44:37 +01:00
langinfo.c misc: Fix various typos 2016-05-31 23:40:21 +02:00
linux_version.c lib/linux_version: fix code indention 2017-01-04 15:42:02 +01:00
loopdev.c misc: add static keyword to where needed [smatch scan] 2017-02-20 12:58:49 +01:00
mangle.c lib: use unique ifdefs for tests 2017-01-04 11:44:37 +01:00
match.c lib/match: fix compiler warning [-Wmissing-prototypes] 2012-07-16 18:29:22 +02:00
mbsalign.c lib/mbsalign: free buffer after error [coverity scan] 2016-10-04 16:14:48 +02:00
mbsedit.c lib/mbsedit: add simple buffer editor 2017-02-16 13:47:44 +01:00
md5.c md5: fix strict aliasing warnings 2012-10-10 11:23:24 +02:00
monotonic.c include: fix sys/sysinfo.h 2016-02-18 16:54:38 +01:00
pager.c lib: use unique ifdefs for tests 2017-01-04 11:44:37 +01:00
parse-date.y lib: add parse-date.y 2017-03-04 10:49:41 -05:00
path.c lib/path: ifdef path_set_prefix() like in path.h 2016-02-11 13:40:25 +01:00
plymouth-ctrl.c misc: spelling, always use "cannot" instead of "can not" 2016-11-30 14:56:50 +01:00
procutils.c lib: use unique ifdefs for tests 2017-01-04 11:44:37 +01:00
randutils.c misc: do not use plain 0 as NULL [smatch scan] 2017-02-20 12:58:49 +01:00
setproctitle.c misc: never cast void* from malloc(3) and friends 2016-03-07 23:29:27 +01:00
strutils.c lib/strutils: return end pointer by isdigit_string() 2017-01-28 12:39:30 +01:00
strv.c lib/strv: add strv_extendv() 2015-10-01 14:43:05 +02:00
swapprober.c textual: "ambivalent" applies to intentions, "ambiguous" to results 2014-10-01 09:37:03 +02:00
sysfs.c docs: Fix word repetitions 2017-02-13 14:10:12 +01:00
terminal-colors.d.5 docs: replace FTP by HTTPS in kernel.org URLs 2016-12-19 11:22:26 +01:00
timer.c misc: do not use plain 0 as NULL [smatch scan] 2017-02-20 12:58:49 +01:00
timeutils.c lib: add timegm() portability function to lib/timeutils.c 2017-02-03 22:31:18 +00:00
ttyutils.c lib: use unique ifdefs for tests 2017-01-04 11:44:37 +01:00