forked from OSchip/llvm-project
Fix unmatching ASan runtime flag for init-order checking exposed by r178158. Add a test for r178158.
llvm-svn: 178229
This commit is contained in:
parent
ac83282665
commit
e586170e86
|
@ -96,7 +96,7 @@ static void ParseFlagsFromString(Flags *f, const char *str) {
|
|||
|
||||
ParseFlag(str, &f->debug, "debug");
|
||||
ParseFlag(str, &f->report_globals, "report_globals");
|
||||
ParseFlag(str, &f->check_initialization_order, "initialization_order");
|
||||
ParseFlag(str, &f->check_initialization_order, "check_initialization_order");
|
||||
ParseFlag(str, &f->malloc_context_size, "malloc_context_size");
|
||||
CHECK((uptr)f->malloc_context_size <= kStackTraceMax);
|
||||
|
||||
|
|
|
@ -63,6 +63,7 @@ TEST(SanitizerCommon, StrFlags) {
|
|||
TestStrFlag("", "--flag_name='abc zxc'", "abc zxc");
|
||||
TestStrFlag("", "--flag_name='abc zxcc'", "abc zxcc");
|
||||
TestStrFlag("", "--flag_name=\"abc qwe\" asd", "abc qwe");
|
||||
TestStrFlag("", "other_flag_name=zzz", "");
|
||||
}
|
||||
|
||||
static void TestTwoFlags(const char *env, bool expected_flag1,
|
||||
|
|
Loading…
Reference in New Issue