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

Unified Diff: extensions/browser/content_hash_reader.h

Issue 512573003: Content verification: Don't fail on non-existence. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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 | extensions/browser/content_hash_reader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/browser/content_hash_reader.h
diff --git a/extensions/browser/content_hash_reader.h b/extensions/browser/content_hash_reader.h
index cc2ea38b925bbdd99a873ceb1dd9edefe2ce2aa9..516897b5d37b4f5d215dcac39e94bbe60d093ec1 100644
--- a/extensions/browser/content_hash_reader.h
+++ b/extensions/browser/content_hash_reader.h
@@ -40,11 +40,15 @@ class ContentHashReader : public base::RefCountedThreadSafe<ContentHashReader> {
// should likely be discarded.
bool Init();
+ // Indicates whether the content in question exists in the local extension
+ // installation. This may be |false| if Init fails.
+ bool content_exists() const { return content_exists_; }
+
// These return whether we found valid verified_contents.json /
// computed_hashes.json files respectively. Note that both of these can be
// true but we still didn't find an entry for |relative_path_| in them.
- bool have_verified_contents() { return have_verified_contents_; }
- bool have_computed_hashes() { return have_computed_hashes_; }
+ bool have_verified_contents() const { return have_verified_contents_; }
+ bool have_computed_hashes() const { return have_computed_hashes_; }
// Return the number of blocks and block size, respectively. Only valid after
// calling Init().
@@ -69,6 +73,8 @@ class ContentHashReader : public base::RefCountedThreadSafe<ContentHashReader> {
InitStatus status_;
+ bool content_exists_;
+
bool have_verified_contents_;
bool have_computed_hashes_;
« no previous file with comments | « no previous file | extensions/browser/content_hash_reader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698