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

Unified Diff: sql/connection.h

Issue 18641004: [sql] Retry Open() if error handler fixed things. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Pointless tweaking, rebase. Created 7 years, 5 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 | sql/connection.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sql/connection.h
diff --git a/sql/connection.h b/sql/connection.h
index 8155a8fd72d1892b1fcc4cab27075ff2f6efb456..1c4d72cfffe31dc0c1c60d1f10b90f5492e8bfe0 100644
--- a/sql/connection.h
+++ b/sql/connection.h
@@ -360,7 +360,14 @@ class SQL_EXPORT Connection {
// Internal initialize function used by both Init and InitInMemory. The file
// name is always 8 bits since we want to use the 8-bit version of
// sqlite3_open. The string can also be sqlite's special ":memory:" string.
- bool OpenInternal(const std::string& file_name);
+ //
+ // |retry_flag| controls retrying the open if the error callback
+ // addressed errors using RazeAndClose().
+ enum Retry {
+ NO_RETRY = 0,
+ RETRY_ON_POISON
+ };
+ bool OpenInternal(const std::string& file_name, Retry retry_flag);
// Internal close function used by Close() and RazeAndClose().
// |forced| indicates that orderly-shutdown checks should not apply.
« no previous file with comments | « no previous file | sql/connection.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698