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

Unified Diff: third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc

Issue 2785943004: DCHECK tasks posted by TaskRunner::PostTask (Closed)
Patch Set: s/CHECK/DCHECK/ except for TaskQueueImpl Created 3 years, 9 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: third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc
diff --git a/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc b/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc
index b2546fc574d45fd0ff580e57d6bc6fc6c4015f9b..291a8a2f3482f163da833f4d07d32a1271d486f4 100644
--- a/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc
+++ b/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.cc
@@ -218,6 +218,10 @@ bool TaskQueueImpl::PostImmediateTaskImpl(
const tracked_objects::Location& from_here,
base::Closure task,
TaskType task_type) {
+ // Use CHECK temporaly to debug http://crbug.com/706854 in the wild.
+ // TODO(tzik): Convert this to DCHECK once the issue is resolved.
+ CHECK(task);
+
base::AutoLock lock(any_thread_lock_);
if (!any_thread().task_queue_manager)
return false;
@@ -236,6 +240,10 @@ bool TaskQueueImpl::PostDelayedTaskImpl(
base::Closure task,
base::TimeDelta delay,
TaskType task_type) {
+ // Use CHECK temporaly to debug http://crbug.com/706854 in the wild.
+ // TODO(tzik): Convert this to DCHECK once the issue is resolved.
+ CHECK(task);
+
DCHECK_GT(delay, base::TimeDelta());
if (base::PlatformThread::CurrentId() == thread_id_) {
// Lock-free fast path for delayed tasks posted from the main thread.
« base/task_scheduler/priority_queue_unittest.cc ('K') | « content/renderer/categorized_worker_pool.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698