logname returns "logname: no login name" with gnome-terminal
Bug #1537645 reported by
Justin Luth
This bug affects 9 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
gnome-terminal (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
Logname fails to return a login name in Xenial Unity. I expected it to return my login name (especially when running as "sudo"). Strangely, it works in gnome-shell and mate editions of Xenial.
It is only a problem with gnome-terminal. It works in xterm and uxterm and in tty1...
Ubuntu Xenial Xerus (development branch) Release 16.04.
logname is unique because it returns the underlying username (and not root) when in sudo mode, so this utility is fairly critical and cannot be substituted with whoami or id -un or any other command that I know of.
See https:/ /bugzilla. gnome.org/ show_bug. cgi?id= 747046