diff options
author | 2012-09-13 15:39:05 +0000 | |
---|---|---|
committer | 2012-09-13 15:39:05 +0000 | |
commit | a56d40f781801d98163a549a05b9bc93e9d32c39 (patch) | |
tree | e157815477e858fff17600e8430d050577237296 /lib/libc/stdlib/realpath.c | |
parent | Update to tzcode2012f. Now that tzcode is in git there are no moe (diff) | |
download | wireguard-openbsd-a56d40f781801d98163a549a05b9bc93e9d32c39.tar.xz wireguard-openbsd-a56d40f781801d98163a549a05b9bc93e9d32c39.zip |
specify the bounds of the dst to strlcat (both values were static and
equal, but it is more correct)
from Michal Mazurek
Diffstat (limited to 'lib/libc/stdlib/realpath.c')
-rw-r--r-- | lib/libc/stdlib/realpath.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/stdlib/realpath.c b/lib/libc/stdlib/realpath.c index 21af4cf005c..534f48d4b4b 100644 --- a/lib/libc/stdlib/realpath.c +++ b/lib/libc/stdlib/realpath.c @@ -1,4 +1,4 @@ -/* $OpenBSD: realpath.c,v 1.14 2011/07/24 21:03:00 miod Exp $ */ +/* $OpenBSD: realpath.c,v 1.15 2012/09/13 15:39:05 deraadt Exp $ */ /* * Copyright (c) 2003 Constantin S. Svintsoff <kostik@iclub.nsu.ru> * @@ -187,7 +187,7 @@ realpath(const char *path, char *resolved) symlink[slen] = '/'; symlink[slen + 1] = 0; } - left_len = strlcat(symlink, left, sizeof(left)); + left_len = strlcat(symlink, left, sizeof(symlink)); if (left_len >= sizeof(left)) { errno = ENAMETOOLONG; goto err; |