On 26/08/15 00:14, 積丹尼 Dan Jacobson wrote: > (info "(coreutils) who invocation") says > > If given no non-option arguments, ‘who’ prints the following > information for each user currently logged on: login name, terminal > line, login time, and remote hostname or X display. > > Say if this means > remote hostname or remote X display. > > or > > X display or remote hostname. > > By the way, now on Debian sid: > > $ who > $ ps a > PID TTY STAT TIME COMMAND > 593 tty7 Ss+ 0:10 /usr/lib/xorg/Xorg :0 -nolisten tcp vt7 > 1310 pts/0 Ss 0:00 bash > 1338 pts/1 Ss 0:00 su - > 1339 pts/1 S+ 0:00 -su > 2005 tty1 Ss+ 0:00 /sbin/agetty --noclear tty1 linux > 2073 pts/0 R+ 0:00 ps a
Could you look a little deeper? who(1) calls read_utmp() from: http://git.sv.gnu.org/gitweb/?p=gnulib.git;a=blob;f=lib/readutmp.c;hb=HEAD thanks, Pádraig.
