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

Unified Diff: net/cert/nss_cert_database_chromeos.cc

Issue 2603173002: Use TaskScheduler instead of WorkerPool in nss_cert_database.cc. (Closed)
Patch Set: self-review Created 3 years, 10 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 | « net/cert/nss_cert_database.cc ('k') | net/cert/nss_cert_database_chromeos_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cert/nss_cert_database_chromeos.cc
diff --git a/net/cert/nss_cert_database_chromeos.cc b/net/cert/nss_cert_database_chromeos.cc
index b6eabcf1dba8cf12764f5cc19c6258c01a8a5428..e3a7dfd0cfe24c96627cad7c20655445a2a9b0a4 100644
--- a/net/cert/nss_cert_database_chromeos.cc
+++ b/net/cert/nss_cert_database_chromeos.cc
@@ -14,7 +14,7 @@
#include "base/bind.h"
#include "base/callback.h"
#include "base/location.h"
-#include "base/task_runner.h"
+#include "base/task_scheduler/post_task.h"
#include "net/base/crypto_module.h"
#include "net/cert/x509_certificate.h"
@@ -49,10 +49,12 @@ void NSSCertDatabaseChromeOS::ListCerts(
// base::Pased will NULL out |certs|, so cache the underlying pointer here.
CertificateList* raw_certs = certs.get();
- GetSlowTaskRunner()->PostTaskAndReply(
- FROM_HERE,
- base::Bind(&NSSCertDatabaseChromeOS::ListCertsImpl,
- profile_filter_,
+ base::PostTaskWithTraitsAndReply(
+ FROM_HERE, base::TaskTraits()
+ .WithShutdownBehavior(
+ base::TaskShutdownBehavior::CONTINUE_ON_SHUTDOWN)
+ .MayBlock(),
+ base::Bind(&NSSCertDatabaseChromeOS::ListCertsImpl, profile_filter_,
base::Unretained(raw_certs)),
base::Bind(callback, base::Passed(&certs)));
}
« no previous file with comments | « net/cert/nss_cert_database.cc ('k') | net/cert/nss_cert_database_chromeos_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698