diff options
Diffstat (limited to 'lib/libc/stdlib/realpath.c')
-rw-r--r-- | lib/libc/stdlib/realpath.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/stdlib/realpath.c b/lib/libc/stdlib/realpath.c index e06db59088f..7b70b9ddfb3 100644 --- a/lib/libc/stdlib/realpath.c +++ b/lib/libc/stdlib/realpath.c @@ -1,4 +1,4 @@ -/* $OpenBSD: realpath.c,v 1.18 2014/10/19 03:56:28 doug Exp $ */ +/* $OpenBSD: realpath.c,v 1.19 2015/01/16 16:48:51 deraadt Exp $ */ /* * Copyright (c) 2003 Constantin S. Svintsoff <kostik@iclub.nsu.ru> * @@ -27,13 +27,13 @@ * SUCH DAMAGE. */ -#include <sys/param.h> #include <sys/stat.h> #include <errno.h> #include <stdlib.h> #include <string.h> #include <unistd.h> +#include <limits.h> /* A slightly modified copy of this file exists in libexec/ld.so */ @@ -156,7 +156,7 @@ realpath(const char *path, char *resolved) goto err; } if (S_ISLNK(sb.st_mode)) { - if (symlinks++ > MAXSYMLINKS) { + if (symlinks++ > SYMLOOP_MAX) { errno = ELOOP; goto err; } |