diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2015-01-16 16:18:08 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2015-01-16 16:18:08 +0000 |
commit | fea0521ff8ac490a72112e6006d4b0cd874e2caf (patch) | |
tree | 2800093cbf05fd89b7b10af19f777934daa8d740 /libexec/ld.so/ldconfig | |
parent | e7cdb4cd2a91c8b67b4be2790814c09ebf9c79b3 (diff) |
<sys/param.h> to <limits.h> conversion. Verified binaries
ok millert, thanks to doug for process advice
Diffstat (limited to 'libexec/ld.so/ldconfig')
-rw-r--r-- | libexec/ld.so/ldconfig/debug.c | 3 | ||||
-rw-r--r-- | libexec/ld.so/ldconfig/dl_prebind.c | 3 | ||||
-rw-r--r-- | libexec/ld.so/ldconfig/ldconfig.c | 6 | ||||
-rw-r--r-- | libexec/ld.so/ldconfig/library.c | 10 | ||||
-rw-r--r-- | libexec/ld.so/ldconfig/prebind.c | 3 | ||||
-rw-r--r-- | libexec/ld.so/ldconfig/shlib.c | 3 |
6 files changed, 12 insertions, 16 deletions
diff --git a/libexec/ld.so/ldconfig/debug.c b/libexec/ld.so/ldconfig/debug.c index 31d466ee3bc..550dac032e3 100644 --- a/libexec/ld.so/ldconfig/debug.c +++ b/libexec/ld.so/ldconfig/debug.c @@ -1,4 +1,4 @@ -/* $OpenBSD: debug.c,v 1.5 2013/12/03 01:47:06 deraadt Exp $ */ +/* $OpenBSD: debug.c,v 1.6 2015/01/16 16:18:07 deraadt Exp $ */ /* * Copyright (c) 2006 Dale Rahn <drahn@dalerahn.com> * @@ -17,7 +17,6 @@ #include <sys/types.h> #include <sys/stat.h> -#include <sys/param.h> #include <sys/mman.h> #include <limits.h> #include <fcntl.h> diff --git a/libexec/ld.so/ldconfig/dl_prebind.c b/libexec/ld.so/ldconfig/dl_prebind.c index 9e50a68db97..151b44062dd 100644 --- a/libexec/ld.so/ldconfig/dl_prebind.c +++ b/libexec/ld.so/ldconfig/dl_prebind.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dl_prebind.c,v 1.2 2008/04/09 21:45:26 kurt Exp $ */ +/* $OpenBSD: dl_prebind.c,v 1.3 2015/01/16 16:18:07 deraadt Exp $ */ /* * Copyright (c) 2006 Dale Rahn <drahn@dalerahn.com> @@ -19,7 +19,6 @@ #include <sys/types.h> #include <sys/mman.h> #include <sys/exec.h> -#include <sys/param.h> #include <sys/sysctl.h> #include <nlist.h> #include <string.h> diff --git a/libexec/ld.so/ldconfig/ldconfig.c b/libexec/ld.so/ldconfig/ldconfig.c index ff9906f1ba0..34ea75b8865 100644 --- a/libexec/ld.so/ldconfig/ldconfig.c +++ b/libexec/ld.so/ldconfig/ldconfig.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ldconfig.c,v 1.32 2013/12/30 21:58:07 deraadt Exp $ */ +/* $OpenBSD: ldconfig.c,v 1.33 2015/01/16 16:18:07 deraadt Exp $ */ /* * Copyright (c) 1993,1995 Paul Kranenburg @@ -30,7 +30,6 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include <sys/param.h> #include <sys/types.h> #include <sys/stat.h> #include <sys/file.h> @@ -49,6 +48,7 @@ #include <stdlib.h> #include <string.h> #include <unistd.h> +#include <limits.h> #include "prebind.h" @@ -202,7 +202,7 @@ dodir(char *dir, int silent) { DIR *dd; struct dirent *dp; - char name[MAXPATHLEN]; + char name[PATH_MAX]; int dewey[MAXDEWEY], ndewey; if ((dd = opendir(dir)) == NULL) { diff --git a/libexec/ld.so/ldconfig/library.c b/libexec/ld.so/ldconfig/library.c index e8e71fa31dc..4b1ff1059e7 100644 --- a/libexec/ld.so/ldconfig/library.c +++ b/libexec/ld.so/ldconfig/library.c @@ -1,4 +1,4 @@ -/* $OpenBSD: library.c,v 1.6 2013/12/03 01:47:06 deraadt Exp $ */ +/* $OpenBSD: library.c,v 1.7 2015/01/16 16:18:07 deraadt Exp $ */ /* * Copyright (c) 2006 Dale Rahn <drahn@dalerahn.com> * @@ -17,7 +17,6 @@ #include <sys/types.h> #include <sys/stat.h> -#include <sys/param.h> #include <sys/mman.h> #include <limits.h> #include <fcntl.h> @@ -27,6 +26,7 @@ #include <string.h> #include <stdlib.h> #include <unistd.h> +#include <limits.h> #include <dirent.h> #include "link.h" #include "sod.h" @@ -151,7 +151,7 @@ elf_load_shlib_hint(struct sod *sod, struct sod *req_sod, return object; } -char elf_hint_store[MAXPATHLEN]; +char elf_hint_store[PATH_MAX]; char * elf_find_shlib(struct sod *sodp, char **searchpath, int nohints) @@ -223,7 +223,7 @@ nohints: match = 1; len = strlcpy( elf_hint_store, *pp, - MAXPATHLEN); + PATH_MAX); if (pp[0][len-1] != '/') { elf_hint_store[len] = '/'; @@ -232,7 +232,7 @@ nohints: strlcpy( &elf_hint_store[len], dp->d_name, - MAXPATHLEN-len); + PATH_MAX-len); if (tsod.sod_major == -1) break; } diff --git a/libexec/ld.so/ldconfig/prebind.c b/libexec/ld.so/ldconfig/prebind.c index 08a2d1ea75e..cb7e4535d49 100644 --- a/libexec/ld.so/ldconfig/prebind.c +++ b/libexec/ld.so/ldconfig/prebind.c @@ -1,4 +1,4 @@ -/* $OpenBSD: prebind.c,v 1.27 2014/10/18 03:19:04 doug Exp $ */ +/* $OpenBSD: prebind.c,v 1.28 2015/01/16 16:18:07 deraadt Exp $ */ /* * Copyright (c) 2006 Dale Rahn <drahn@dalerahn.com> * @@ -17,7 +17,6 @@ #include <sys/types.h> #include <sys/stat.h> -#include <sys/param.h> #include <sys/mman.h> #include <limits.h> #include <errno.h> diff --git a/libexec/ld.so/ldconfig/shlib.c b/libexec/ld.so/ldconfig/shlib.c index def2ac0a7dc..17ba7c4669e 100644 --- a/libexec/ld.so/ldconfig/shlib.c +++ b/libexec/ld.so/ldconfig/shlib.c @@ -1,4 +1,4 @@ -/* $OpenBSD: shlib.c,v 1.9 2006/05/13 16:33:40 deraadt Exp $ */ +/* $OpenBSD: shlib.c,v 1.10 2015/01/16 16:18:07 deraadt Exp $ */ /* $NetBSD: shlib.c,v 1.13 1998/04/04 01:00:29 fvdl Exp $ */ /* @@ -32,7 +32,6 @@ * */ -#include <sys/param.h> #include <sys/types.h> #include <sys/stat.h> #include <sys/file.h> |