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

Unified Diff: net/tools/cert_verify_tool/verify_using_path_builder.cc

Issue 2595723002: Allow CertNetFetcher to be shutdown from the network thread (Closed)
Patch Set: tweak comments Created 4 years 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: net/tools/cert_verify_tool/verify_using_path_builder.cc
diff --git a/net/tools/cert_verify_tool/verify_using_path_builder.cc b/net/tools/cert_verify_tool/verify_using_path_builder.cc
index adaf5fe5d81aab62aa3d1b15f25d57e62acc3d14..3878624b810df9d87f6d26d8ef586dd66318f6fa 100644
--- a/net/tools/cert_verify_tool/verify_using_path_builder.cc
+++ b/net/tools/cert_verify_tool/verify_using_path_builder.cc
@@ -284,17 +284,19 @@ bool VerifyUsingPathBuilder(
base::Thread::Options options(base::MessageLoop::TYPE_IO, 0);
base::Thread thread("network_thread");
CHECK(thread.StartWithOptions(options));
+
scoped_refptr<URLRequestContextGetterForAia> url_request_context_getter(
new URLRequestContextGetterForAia(thread.task_runner()));
+ // Create a CertNetFetcher to be initialized on the network thread.
auto cert_net_fetcher =
- CreateCertNetFetcher(url_request_context_getter.get());
+ CreateCertNetFetcherOnCallerThread(url_request_context_getter.get());
net::CertIssuerSourceAia aia_cert_issuer_source(cert_net_fetcher.get());
eroman 2017/01/03 20:42:38 net::CertIssuerSourceAia should be updated to hold
estark 2017/01/05 19:08:40 Done.
path_builder.AddCertIssuerSource(&aia_cert_issuer_source);
// Run the path builder.
path_builder.Run();
- // Stop the temporary network thread..
+ // Stop the temporary network thread.
url_request_context_getter->ShutDown();
thread.Stop();

Powered by Google App Engine
This is Rietveld 408576698