diff options
author | ed <ed@FreeBSD.org> | 2008-11-16 14:43:33 +0000 |
---|---|---|
committer | ed <ed@FreeBSD.org> | 2008-11-16 14:43:33 +0000 |
commit | dc9c7a01f603ba4ee1c58ac4433a0362c52c0286 (patch) | |
tree | 72943ade1d243fc64c6d4a40fd5dbe60be41e2c0 /include | |
parent | 89701909aa1a94e04b555eb5d9ace17db0c3e068 (diff) | |
download | FreeBSD-src-dc9c7a01f603ba4ee1c58ac4433a0362c52c0286.zip FreeBSD-src-dc9c7a01f603ba4ee1c58ac4433a0362c52c0286.tar.gz |
Add a comment to utmp.h about the sizes of UT_HOSTSIZE and UT_LINESIZE.
UT_HOSTSIZE and UT_LINESIZE are too small right now. If we ever bump
UT_HOSTSIZE, we must not forget to increase UT_LINESIZE as well. If we
add a comment, we're pretty sure we increase both values at the same
time.
PR: bin/108743 (maybe others)
Diffstat (limited to 'include')
-rw-r--r-- | include/utmp.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/utmp.h b/include/utmp.h index bdf137b..1b57bb8 100644 --- a/include/utmp.h +++ b/include/utmp.h @@ -46,6 +46,13 @@ #define _PATH_WTMP "/var/log/wtmp" #define _PATH_LASTLOG "/var/log/lastlog" +/* + * XXX: These values are too low, but cannot be changed without breaking + * the file format. Right now pts(4) is limited to 1000 instances, + * because /dev/pts/1000 would require UT_LINESIZE to be bigger. + * UT_HOSTSIZE is also too small to hold most common hostnames or IPv6 + * addresses. + */ #define UT_NAMESIZE 16 /* see MAXLOGNAME in <sys/param.h> */ #define UT_LINESIZE 8 #define UT_HOSTSIZE 16 |