"Guido Leenders" <[EMAIL PROTECTED]> writes: > It would be very nice if 'who' had an option to print all 32 characters of > the username available in utmp.
As near as I can make out, 'who' is violating the POSIX specification when it truncates the user name. Also, I notice that Solaris 8 'who' does not truncate. I don't see any good reason for 'who' to truncate, so here's a patch. 2004-06-19 Paul Eggert <[EMAIL PROTECTED]> * src/who.c (print_line): Don't truncate user names at 8 bytes. Problem reported by Guido Leenders in: http://lists.gnu.org/archive/html/bug-coreutils/2004-06/msg00056.html * NEWS: document this. Index: src/who.c =================================================================== RCS file: /home/meyering/coreutils/cu/src/who.c,v retrieving revision 1.94 diff -p -u -r1.94 who.c --- src/who.c 13 Jun 2004 22:03:07 -0000 1.94 +++ src/who.c 19 Jun 2004 22:25:47 -0000 @@ -272,7 +272,7 @@ print_line (const char *user, const char *x_exitstr = '\0'; err = asprintf (&buf, - "%-8.8s" + "%-8s" "%s" " %-12s" " %-12s" Index: NEWS =================================================================== RCS file: /home/meyering/coreutils/cu/NEWS,v retrieving revision 1.216 diff -p -u -r1.216 NEWS --- NEWS 17 Jun 2004 14:42:05 -0000 1.216 +++ NEWS 20 Jun 2004 04:23:36 -0000 @@ -55,6 +55,8 @@ GNU coreutils NEWS POSIXLY_CORRECT is set and the first argument is not "-n", echo now outputs all option-like arguments instead of treating them as options. + who now prints user names in full instead of truncating them after 8 bytes. + ** New features For efficiency, `sort -m' no longer copies input to a temporary file _______________________________________________ Bug-coreutils mailing list [EMAIL PROTECTED] http://lists.gnu.org/mailman/listinfo/bug-coreutils