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

Unified Diff: src/heap/memory-reducer.cc

Issue 1234513003: Correctly handle the case when TimerTask is destroyed with being run. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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
« no previous file with comments | « src/heap/memory-reducer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/memory-reducer.cc
diff --git a/src/heap/memory-reducer.cc b/src/heap/memory-reducer.cc
index 2e0ccb9de6a07ebac1ea37141af7e25c7586f487..c89d1424e7c5e78e303ae64b7043669571bb4035 100644
--- a/src/heap/memory-reducer.cc
+++ b/src/heap/memory-reducer.cc
@@ -177,6 +177,13 @@ void MemoryReducer::ScheduleTimer(double delay_ms) {
}
+void MemoryReducer::ClearTask(v8::Task* task) {
+ if (pending_task_ == task) {
+ pending_task_ = nullptr;
+ }
+}
+
+
void MemoryReducer::TearDown() {
if (pending_task_ != nullptr) {
pending_task_->NotifyHeapTearDown();
« no previous file with comments | « src/heap/memory-reducer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698