summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorkosak <kosak@google.com>2013-12-03 22:38:22 (GMT)
committerkosak <kosak@google.com>2013-12-03 22:38:22 (GMT)
commit37b97d1c93fb8283f8bbf54f5618c1c1e5a4726a (patch)
tree0949bd9f08f265d8b29d513095775a69964dee0e /include
parentaa34ae250800af7e98499abba44636503cf99b16 (diff)
downloadgoogletest-37b97d1c93fb8283f8bbf54f5618c1c1e5a4726a.zip
googletest-37b97d1c93fb8283f8bbf54f5618c1c1e5a4726a.tar.gz
googletest-37b97d1c93fb8283f8bbf54f5618c1c1e5a4726a.tar.bz2
Add MemorySanitizer annotations in gtest printers. Also remove unused variable kPathSeparatorString.
Diffstat (limited to 'include')
-rw-r--r--include/gtest/internal/gtest-port.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/gtest/internal/gtest-port.h b/include/gtest/internal/gtest-port.h
index dc4fe0c..a6726b4 100644
--- a/include/gtest/internal/gtest-port.h
+++ b/include/gtest/internal/gtest-port.h
@@ -782,6 +782,19 @@ using ::std::tuple_size;
# define GTEST_HAS_CXXABI_H_ 0
#endif
+// A function level attribute to disable checking for use of uninitialized
+// memory when built with MemorySanitizer.
+#if defined(__clang__)
+# if __has_feature(memory_sanitizer)
+# define GTEST_ATTRIBUTE_NO_SANITIZE_MEMORY_ \
+ __attribute__((no_sanitize_memory))
+# else
+# define GTEST_ATTRIBUTE_NO_SANITIZE_MEMORY_
+# endif
+#else
+# define GTEST_ATTRIBUTE_NO_SANITIZE_MEMORY_
+#endif
+
namespace testing {
class Message;