mirror of
https://github.com/flutter/flutter.git
synced 2025-06-03 00:51:18 +00:00
Wire up memory sanitizer. (#321)
This commit is contained in:
parent
41b6918f1c
commit
eb6a23609d
@ -280,6 +280,10 @@ if (!is_clang && (is_asan || is_lsan || is_tsan || is_msan)) {
|
||||
is_clang = true
|
||||
}
|
||||
|
||||
if (is_msan && !is_linux) {
|
||||
assert(false, "Memory sanitizer is only available on Linux.")
|
||||
}
|
||||
|
||||
# =============================================================================
|
||||
# TARGET DEFAULTS
|
||||
# =============================================================================
|
||||
|
@ -127,13 +127,8 @@ config("compiler") {
|
||||
ldflags += [ "-fsanitize=thread" ]
|
||||
}
|
||||
if (is_msan) {
|
||||
msan_blacklist_path =
|
||||
rebase_path("//tools/msan/blacklist.txt", root_build_dir)
|
||||
cflags += [
|
||||
"-fsanitize=memory",
|
||||
"-fsanitize-memory-track-origins=$msan_track_origins",
|
||||
"-fsanitize-blacklist=$msan_blacklist_path",
|
||||
]
|
||||
cflags += [ "-fsanitize=memory" ]
|
||||
ldflags += [ "-fsanitize=memory" ]
|
||||
}
|
||||
|
||||
if (use_custom_libcxx) {
|
||||
|
Loading…
Reference in New Issue
Block a user