Skip to content

Commit a05f591

Browse files
sjindel-googlecommit-bot@chromium.org
authored andcommitted
[vm/ffi] Delete helper thread in ffi/function_gc_test
Fixes memory leak on ASAN bot. Change-Id: Idbfd1e66b703e1203fec027a040147179dd0752d Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/112343 Auto-Submit: Samir Jindel <[email protected]> Reviewed-by: Martin Kustermann <[email protected]> Commit-Queue: Samir Jindel <[email protected]>
1 parent cd3b34f commit a05f591

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

runtime/bin/ffi_test/ffi_test_functions.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -575,6 +575,7 @@ DART_EXPORT void* UnprotectCode() {
575575
DART_EXPORT void WaitForHelper(void* helper) {
576576
std::thread* thread = reinterpret_cast<std::thread*>(helper);
577577
thread->join();
578+
delete thread;
578579
}
579580
#else
580581
// Our version of VSC++ doesn't support std::thread yet.

0 commit comments

Comments
 (0)