| Index: sql/connection.cc
|
| diff --git a/sql/connection.cc b/sql/connection.cc
|
| index 9c7cb7d4099a811bc78b314070ab2fd1eebb1eb4..1238662c948cdcd299e7f9b5440bc21d9a726d96 100644
|
| --- a/sql/connection.cc
|
| +++ b/sql/connection.cc
|
| @@ -31,6 +31,7 @@
|
| #include "base/threading/thread_task_runner_handle.h"
|
| #include "base/trace_event/memory_dump_manager.h"
|
| #include "sql/connection_memory_dump_provider.h"
|
| +#include "sql/error_delegate_util.h"
|
| #include "sql/meta_table.h"
|
| #include "sql/statement.h"
|
| #include "third_party/sqlite/sqlite3.h"
|
| @@ -1700,8 +1701,13 @@ bool Connection::OpenInternal(const std::string& file_name,
|
| // land is. If it's mostly SQLITE_NOTADB, then the database should
|
| // be razed.
|
| err = ExecuteAndReturnErrorCode("PRAGMA auto_vacuum");
|
| - if (err != SQLITE_OK)
|
| + if (err != SQLITE_OK) {
|
| UMA_HISTOGRAM_SPARSE_SLOWLY("Sqlite.OpenProbeFailure", err);
|
| + if (IsErrorCatastrophic(err)) {
|
| + OnSqliteError(err, nullptr, "PRAGMA auto_vacuum");
|
| + return false;
|
| + }
|
| + }
|
|
|
| #if defined(OS_IOS) && defined(USE_SYSTEM_SQLITE)
|
| // The version of SQLite shipped with iOS doesn't enable ICU, which includes
|
|
|