diff --git a/bin/ps/keyword.c b/bin/ps/keyword.c index 4bc00fc7e8a6..5e4f37f9e521 100644 --- a/bin/ps/keyword.c +++ b/bin/ps/keyword.c @@ -51,7 +51,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include "ps.h" @@ -75,7 +74,7 @@ int utime(), stime(), ixrss(), idrss(), isrss(); #define UIDLEN 5 #define PIDFMT "d" #define PIDLEN 5 -#define USERLEN UT_NAMESIZE +#define USERLEN (MAXLOGNAME - 1) static VAR var[] = { {"%cpu", "%CPU", NULL, 0, pcpu, NULL, 4, 0, CHAR, NULL, 0}, diff --git a/bin/ps/ps.c b/bin/ps/ps.c index 8b23a1da4a3c..1bb1e505348d 100644 --- a/bin/ps/ps.c +++ b/bin/ps/ps.c @@ -63,7 +63,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include "lomac.h" #include "ps.h" @@ -419,7 +418,7 @@ main(int argc, char *argv[]) uid_t * getuids(const char *arg, int *nuids) { - char name[UT_NAMESIZE + 1]; + char name[MAXLOGNAME]; struct passwd *pwd; uid_t *uids, *moreuids; int alloc;