Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(925)

Unified Diff: runtime/vm/virtual_memory_linux.cc

Issue 2191723002: Fix race condition with HasMutatorThread that was being used without a lock. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Address self review comments. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: runtime/vm/virtual_memory_linux.cc
diff --git a/runtime/vm/virtual_memory_linux.cc b/runtime/vm/virtual_memory_linux.cc
index 8973345c340354719db44941b528ebb4237dc09f..0228f68d975ca318ff6727f7e1a20a85d88a9e2c 100644
--- a/runtime/vm/virtual_memory_linux.cc
+++ b/runtime/vm/virtual_memory_linux.cc
@@ -82,7 +82,6 @@ bool VirtualMemory::Commit(uword addr, intptr_t size, bool executable) {
bool VirtualMemory::Protect(void* address, intptr_t size, Protection mode) {
ASSERT(Thread::Current()->IsMutatorThread() ||
- !Isolate::Current()->HasMutatorThread() ||
Isolate::Current()->mutator_thread()->IsAtSafepoint());
uword start_address = reinterpret_cast<uword>(address);
uword end_address = start_address + size;

Powered by Google App Engine
This is Rietveld 408576698