The logname documentation is silent concerning its implementation. It appears to rely on getlogin(), which is known to have limitations (or bugs)[*]. Even though such limitations may be documented in the getlogin documentation, the user isn't necessarily aware that they affect logname.
[*] http://austingroupbugs.net/view.php?id=172 and the getlogin(3) man page under GNU/Linux. -- Vincent Lefèvre <vinc...@vinc17.net> - Web: <http://www.vinc17.net/> 100% accessible validated (X)HTML - Blog: <http://www.vinc17.net/blog/> Work: CR INRIA - computer arithmetic / Arénaire project (LIP, ENS-Lyon)