diff options
author | 2015-01-16 06:39:28 +0000 | |
---|---|---|
committer | 2015-01-16 06:39:28 +0000 | |
commit | b9fc9a728fce9c4289b7e9a992665e28d5629a54 (patch) | |
tree | 72b2433e418dfa1aef5fcf8305617b97979a25d8 /bin/csh/csh.c | |
parent | improve checksum parsing slightly. now handles filenames with spaces. (diff) | |
download | wireguard-openbsd-b9fc9a728fce9c4289b7e9a992665e28d5629a54.tar.xz wireguard-openbsd-b9fc9a728fce9c4289b7e9a992665e28d5629a54.zip |
Replace <sys/param.h> with <limits.h> and other less dirty headers where
possible. Annotate <sys/param.h> lines with their current reasons. Switch
to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc. Change
MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where
sensible to avoid pulling in the pollution. These are the files confirmed
through binary verification.
ok guenther, millert, doug (helped with the verification protocol)
Diffstat (limited to 'bin/csh/csh.c')
-rw-r--r-- | bin/csh/csh.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/csh/csh.c b/bin/csh/csh.c index fb908d3f9d8..c1d88b80c3a 100644 --- a/bin/csh/csh.c +++ b/bin/csh/csh.c @@ -1,4 +1,4 @@ -/* $OpenBSD: csh.c,v 1.26 2014/10/16 19:43:31 deraadt Exp $ */ +/* $OpenBSD: csh.c,v 1.27 2015/01/16 06:39:31 deraadt Exp $ */ /* $NetBSD: csh.c,v 1.14 1995/04/29 23:21:28 mycroft Exp $ */ /*- @@ -33,7 +33,6 @@ #include <sys/types.h> #include <sys/ioctl.h> #include <sys/stat.h> -#include <sys/param.h> #include <fcntl.h> #include <errno.h> #include <pwd.h> @@ -41,6 +40,7 @@ #include <string.h> #include <locale.h> #include <unistd.h> +#include <limits.h> #include <vis.h> #include <stdarg.h> @@ -207,7 +207,7 @@ main(int argc, char *argv[]) */ set(STRstatus, Strsave(STR0)); - if ((tcp = getenv("HOME")) != NULL && strlen(tcp) < MAXPATHLEN) + if ((tcp = getenv("HOME")) != NULL && strlen(tcp) < PATH_MAX) cp = SAVE(tcp); else cp = NULL; |