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

Unified Diff: net/cert/cert_verifier.h

Issue 1131173005: Improve documentation of CertVerifier::Verify() regarding |out_req|. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix, and verify compiles Created 5 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cert/cert_verifier.h
diff --git a/net/cert/cert_verifier.h b/net/cert/cert_verifier.h
index aaab36c83c2daaaf416904bf91a6e2f5e5782be3..0c74fa7ccd8a7f7b0de5b8f0542356da005517ca 100644
--- a/net/cert/cert_verifier.h
+++ b/net/cert/cert_verifier.h
@@ -25,8 +25,13 @@ class NET_EXPORT CertVerifier {
public:
class Request {
public:
+ Request() {}
+
// Destruction of the Request cancels it.
virtual ~Request() {}
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Request);
};
enum VerifyFlags {
@@ -99,8 +104,13 @@ class NET_EXPORT CertVerifier {
// could not be completed synchronously, in which case the result code will
// be passed to the callback when available.
//
- // |*out_req| will be filled with a pointer to the asynchronous request.
- // Freeing this pointer before the request has completed will cancel it.
+ // On asynchronous completion (when Verify returns ERR_IO_PENDING) |out_req|
+ // will be reset with a pointer to the request. Freeing this pointer before
+ // the request has completed will cancel it.
+ //
+ // If Verify() completes synchronously then |out_req| *may* be reset to
+ // nullptr. However it is not guaranteed that all implementations will reset
+ // it in this case.
//
// TODO(rsleevi): Move CRLSet* out of the CertVerifier signature.
virtual int Verify(X509Certificate* cert,
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698