OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/appcache/appcache_database.h" | 5 #include "content/browser/appcache/appcache_database.h" |
6 | 6 |
7 #include "base/auto_reset.h" | 7 #include "base/auto_reset.h" |
8 #include "base/bind.h" | 8 #include "base/bind.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/files/file_util.h" | 10 #include "base/files/file_util.h" |
11 #include "base/logging.h" | 11 #include "base/logging.h" |
| 12 #include "base/macros.h" |
12 #include "base/strings/utf_string_conversions.h" | 13 #include "base/strings/utf_string_conversions.h" |
13 #include "content/browser/appcache/appcache_entry.h" | 14 #include "content/browser/appcache/appcache_entry.h" |
14 #include "content/browser/appcache/appcache_histograms.h" | 15 #include "content/browser/appcache/appcache_histograms.h" |
15 #include "sql/connection.h" | 16 #include "sql/connection.h" |
16 #include "sql/error_delegate_util.h" | 17 #include "sql/error_delegate_util.h" |
17 #include "sql/meta_table.h" | 18 #include "sql/meta_table.h" |
18 #include "sql/statement.h" | 19 #include "sql/statement.h" |
19 #include "sql/transaction.h" | 20 #include "sql/transaction.h" |
20 | 21 |
21 namespace content { | 22 namespace content { |
(...skipping 1295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1317 } | 1318 } |
1318 | 1319 |
1319 void AppCacheDatabase::OnDatabaseError(int err, sql::Statement* stmt) { | 1320 void AppCacheDatabase::OnDatabaseError(int err, sql::Statement* stmt) { |
1320 was_corruption_detected_ |= sql::IsErrorCatastrophic(err); | 1321 was_corruption_detected_ |= sql::IsErrorCatastrophic(err); |
1321 if (!db_->ShouldIgnoreSqliteError(err)) | 1322 if (!db_->ShouldIgnoreSqliteError(err)) |
1322 DLOG(ERROR) << db_->GetErrorMessage(); | 1323 DLOG(ERROR) << db_->GetErrorMessage(); |
1323 // TODO: Maybe use non-catostrophic errors to trigger a full integrity check? | 1324 // TODO: Maybe use non-catostrophic errors to trigger a full integrity check? |
1324 } | 1325 } |
1325 | 1326 |
1326 } // namespace content | 1327 } // namespace content |
OLD | NEW |