[vm/concurrency] When waking up ThreadInterrupter first check if it is shutdown already.
Fixes https://github.com/dart-lang/sdk/issues/42302 Change-Id: Ic250ce6d23d20d0435447c4e3ba546c1755c0458 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/151024 Reviewed-by: Ryan Macnak <rmacnak@google.com> Commit-Queue: Alexander Aprelev <aam@google.com>
This commit is contained in:
committed by
commit-bot@chromium.org
parent
0b64f54889
commit
c1f0bc310d
@@ -146,6 +146,10 @@ void ThreadInterrupter::WakeUp() {
|
||||
}
|
||||
{
|
||||
MonitorLocker ml(monitor_);
|
||||
if (shutdown_) {
|
||||
// Late call
|
||||
return;
|
||||
}
|
||||
if (!initialized_) {
|
||||
// Early call.
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user