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

Unified Diff: net/cert_net/cert_net_fetcher_impl.h

Issue 2595723002: Allow CertNetFetcher to be shutdown from the network thread (Closed)
Patch Set: update comments Created 3 years, 11 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/internal/cert_issuer_source_aia_unittest.cc ('k') | net/cert_net/cert_net_fetcher_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cert_net/cert_net_fetcher_impl.h
diff --git a/net/cert_net/cert_net_fetcher_impl.h b/net/cert_net/cert_net_fetcher_impl.h
index d4add24c2ffd96d2dfe8541efe9d6d19d6ce831a..c863fda7f01e0def3c5baa281c1416c62646754e 100644
--- a/net/cert_net/cert_net_fetcher_impl.h
+++ b/net/cert_net/cert_net_fetcher_impl.h
@@ -7,21 +7,21 @@
#include <memory>
+#include "base/memory/ref_counted.h"
#include "net/base/net_export.h"
namespace net {
class CertNetFetcher;
-class URLRequestContextGetter;
+class URLRequestContext;
// Creates a CertNetFetcher that issues requests through the provided
-// URLRequestContext.
-//
-// The returned CertNetFetcher is to be operated on a thread *other* than the
-// thread used for the URLRequestContext (since it gives a blocking interface
-// to URL fetching).
-NET_EXPORT std::unique_ptr<CertNetFetcher> CreateCertNetFetcher(
- URLRequestContextGetter* context_getter);
+// URLRequestContext. The URLRequestContext must stay valid until the returned
+// CertNetFetcher's Shutdown method is called. The CertNetFetcher is to be
+// created and shutdown on the network thread. Its Fetch methods are to be used
+// on a *different* thread, since it gives a blocking interface to URL fetching.
+NET_EXPORT scoped_refptr<CertNetFetcher> CreateCertNetFetcher(
+ URLRequestContext* context);
} // namespace net
« no previous file with comments | « net/cert/internal/cert_issuer_source_aia_unittest.cc ('k') | net/cert_net/cert_net_fetcher_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698