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

Unified Diff: chrome/browser/webdata/web_database.cc

Issue 270101: Move the sqlite error handler to a single location... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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
Index: chrome/browser/webdata/web_database.cc
===================================================================
--- chrome/browser/webdata/web_database.cc (revision 28907)
+++ chrome/browser/webdata/web_database.cc (working copy)
@@ -14,6 +14,7 @@
#include "app/sql/transaction.h"
#include "base/string_util.h"
#include "base/time.h"
+#include "chrome/browser/diagnostics/sqlite_diagnostics.h"
#include "chrome/browser/history/history_database.h"
#include "chrome/browser/search_engines/template_url.h"
#include "webkit/glue/password_form.h"
@@ -133,6 +134,9 @@
}
bool WebDatabase::Init(const FilePath& db_name) {
+ // Set the exceptional sqlite error handler.
+ db_.set_error_delegate(GetErrorHandlerForWebDb());
+
// We don't store that much data in the tables so use a small page size.
// This provides a large benefit for empty tables (which is very likely with
// the tables we create).

Powered by Google App Engine
This is Rietveld 408576698