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

Unified Diff: extensions/browser/value_store/lazy_leveldb.cc

Issue 2799543002: Avoid status strings on successful ValueStore status. (Closed)
Patch Set: Created 3 years, 8 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: extensions/browser/value_store/lazy_leveldb.cc
diff --git a/extensions/browser/value_store/lazy_leveldb.cc b/extensions/browser/value_store/lazy_leveldb.cc
index 8176b8395f2a6e983c752d2ed33d6315fe6edc61..ca5501d075f90b056b7d8a160d15dbf76e26d90e 100644
--- a/extensions/browser/value_store/lazy_leveldb.cc
+++ b/extensions/browser/value_store/lazy_leveldb.cc
@@ -253,6 +253,9 @@ ValueStore::Status LazyLevelDb::EnsureDbIsOpen() {
ValueStore::Status LazyLevelDb::ToValueStoreError(
const leveldb::Status& status) {
+ if (status.ok())
+ return ValueStore::Status();
+
CHECK(!status.IsNotFound()); // not an error
std::string message = status.ToString();
« 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