Date: Thu, 14 Jan 1999 18:15:23 +0000 From: Ben Smithurst <ben@scientia.demon.co.uk> To: freebsd-current@FreeBSD.ORG Subject: minor nit: user name length in sa(8) Message-ID: <19990114181523.A16865@scientia.demon.co.uk>
next in thread | raw e-mail | index | archive | help
Looks like sa(8) needs to be updated to recognize 16 character user names. (It seems odd that this hasn't been fixed yet, is there some reason other than oversight why not?) --- src/usr.sbin/sa/usrdb.c~ Thu Jan 14 17:51:10 1999 +++ src/usr.sbin/sa/usrdb.c Thu Jan 14 18:00:07 1999 @@ -35,6 +35,7 @@ #include <sys/types.h> #include <sys/acct.h> +#include <sys/param.h> #include <err.h> #include <errno.h> #include <fcntl.h> @@ -236,7 +237,7 @@ while (rv == 0) { ui = (struct userinfo *) data.data; - printf("%-8s %9qu ", + printf("%-*s %9qu ", MAXLOGNAME - 1, user_from_uid(ui->ui_uid, 0), ui->ui_calls); t = (double) (ui->ui_utime + ui->ui_stime) / -- Ben Smithurst ben@scientia.demon.co.uk send a blank message to ben+pgp@scientia.demon.co.uk for PGP key To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19990114181523.A16865>