Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/gpl3/gcc/dist/libsanitizer/asan Ignore the first dl...
details: https://anonhg.NetBSD.org/src/rev/3c7d9e9da551
branches: trunk
changeset: 345550:3c7d9e9da551
user: christos <christos%NetBSD.org@localhost>
date: Wed Jun 01 00:53:35 2016 +0000
description:
Ignore the first dlpi entry which is ourselves on NetBSD instead of having
a NULL name as on linux.
diffstat:
external/gpl3/gcc/dist/libsanitizer/asan/asan_linux.cc | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
diffs (19 lines):
diff -r f721296f944e -r 3c7d9e9da551 external/gpl3/gcc/dist/libsanitizer/asan/asan_linux.cc
--- a/external/gpl3/gcc/dist/libsanitizer/asan/asan_linux.cc Wed Jun 01 00:49:44 2016 +0000
+++ b/external/gpl3/gcc/dist/libsanitizer/asan/asan_linux.cc Wed Jun 01 00:53:35 2016 +0000
@@ -95,6 +95,15 @@
if (internal_strncmp(info->dlpi_name, "linux-", sizeof("linux-") - 1) == 0)
return 0;
+#if SANITIZER_NETBSD
+ // Ignore first entry (the main program)
+ char **p = (char **)data;
+ if (*p == NULL) {
+ *p = (char *)-1;
+ return 0;
+ }
+#endif
+
*(const char **)data = info->dlpi_name;
return 1;
}
Home |
Main Index |
Thread Index |
Old Index