aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2018-02-16 19:10:37 +0000
committerDimitry Andric <dim@FreeBSD.org>2018-02-16 19:10:37 +0000
commit2fb14b72339e21350fc3b98a9fdb684b9e194350 (patch)
tree19318c1ad0e87ca614c0e88606177d8352e2d97d
parentee3c57deda66b10eddf3f49d2a11fbbd05cddce1 (diff)
downloadsrc-2fb14b72339e21350fc3b98a9fdb684b9e194350.tar.gz
src-2fb14b72339e21350fc3b98a9fdb684b9e194350.zip
Notes
Notes: svn path=/vendor/compiler-rt/dist-release_60/; revision=329398 svn path=/vendor/compiler-rt/compiler-rt-release_600-r326565/; revision=330379; tag=vendor/compiler-rt/compiler-rt-release_600-r326565
-rw-r--r--lib/asan/asan_linux.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/asan/asan_linux.cc b/lib/asan/asan_linux.cc
index 047e1dbb72fa..625f32d408df 100644
--- a/lib/asan/asan_linux.cc
+++ b/lib/asan/asan_linux.cc
@@ -32,6 +32,7 @@
#include <sys/types.h>
#include <dlfcn.h>
#include <fcntl.h>
+#include <limits.h>
#include <pthread.h>
#include <stdio.h>
#include <unistd.h>
@@ -214,7 +215,7 @@ void AsanCheckIncompatibleRT() {
// the functions in dynamic ASan runtime instead of the functions in
// system libraries, causing crashes later in ASan initialization.
MemoryMappingLayout proc_maps(/*cache_enabled*/true);
- char filename[128];
+ char filename[PATH_MAX];
MemoryMappedSegment segment(filename, sizeof(filename));
while (proc_maps.Next(&segment)) {
if (IsDynamicRTName(segment.filename)) {