]> granicus.if.org Git - sudo/commit
Rototill code to determine the tty. For Linux, we now look up the
authorTodd C. Miller <Todd.Miller@courtesan.com>
Wed, 23 May 2012 16:46:39 +0000 (12:46 -0400)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Wed, 23 May 2012 16:46:39 +0000 (12:46 -0400)
commit8ff1629ff050aedb6ca1c3688ae0b435d3e62a50
tree0f9a0f4be0e219bbb0faddb4eb6a99375ee87d06
parentfb5b251badb4727a5ce86511e00e7c7c83e1a375
Rototill code to determine the tty.  For Linux, we now look up the
tty device in /proc/pid/stat instead of trying to open /proc/pid/fd/[0-2].
The sudo_ttyname_dev() function maps the given device number to a
string.  On BSD, we can use devname().  On Solaris, _ttyname_dev()
does what we want.  For others we do a breadth-first search of /dev.

--HG--
branch : 1.7
config.h.in
configure
configure.in
ttyname.c