Merge "Fix missing null-terminator to exec call." am: 7587e20eaf

Original change: https://android-review.googlesource.com/c/platform/bionic/+/2073947

Change-Id: Id15a4a4e86f6bb05378ec1f775fb07693bd9fbda
Ignore-AOSP-First: this is an automerge
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
(cherry picked from commit 0f46547800)
This commit is contained in:
Florian Mayer 2022-04-23 01:46:25 +00:00 committed by Hongguang Chen
parent 22dfc589ee
commit bbe7c690f1

View file

@ -43,7 +43,7 @@ void RunGwpAsanTest(const char* test_name) {
std::string filter_arg = "--gtest_filter=";
filter_arg += test_name;
std::string exec(testing::internal::GetArgvs()[0]);
eh.SetArgs({exec.c_str(), "--gtest_also_run_disabled_tests", filter_arg.c_str()});
eh.SetArgs({exec.c_str(), "--gtest_also_run_disabled_tests", filter_arg.c_str(), nullptr});
eh.Run([&]() { execve(exec.c_str(), eh.GetArgs(), eh.GetEnv()); },
/* expected_exit_status */ 0,
// |expected_output_regex|, ensure at least one test ran: