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

Side by Side Diff: content/browser/appcache/appcache_database.cc

Issue 344493002: Move all remaining appcache-related code to content namespace (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "webkit/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/file_util.h" 10 #include "base/file_util.h"
11 #include "base/logging.h" 11 #include "base/logging.h"
12 #include "base/strings/utf_string_conversions.h" 12 #include "base/strings/utf_string_conversions.h"
13 #include "content/browser/appcache/appcache_entry.h"
14 #include "content/browser/appcache/appcache_histograms.h"
13 #include "sql/connection.h" 15 #include "sql/connection.h"
14 #include "sql/error_delegate_util.h" 16 #include "sql/error_delegate_util.h"
15 #include "sql/meta_table.h" 17 #include "sql/meta_table.h"
16 #include "sql/statement.h" 18 #include "sql/statement.h"
17 #include "sql/transaction.h" 19 #include "sql/transaction.h"
18 #include "webkit/browser/appcache/appcache_entry.h"
19 #include "webkit/browser/appcache/appcache_histograms.h"
20 20
21 namespace appcache { 21 namespace content {
22 22
23 // Schema ------------------------------------------------------------------- 23 // Schema -------------------------------------------------------------------
24 namespace { 24 namespace {
25 25
26 #if defined(APPCACHE_USE_SIMPLE_CACHE) 26 #if defined(APPCACHE_USE_SIMPLE_CACHE)
27 const int kCurrentVersion = 6; 27 const int kCurrentVersion = 6;
28 const int kCompatibleVersion = 6; 28 const int kCompatibleVersion = 6;
29 #else 29 #else
30 const int kCurrentVersion = 5; 30 const int kCurrentVersion = 5;
31 const int kCompatibleVersion = 5; 31 const int kCompatibleVersion = 5;
(...skipping 1184 matching lines...) Expand 10 before | Expand all | Expand 10 after
1216 return LazyOpen(true); 1216 return LazyOpen(true);
1217 } 1217 }
1218 1218
1219 void AppCacheDatabase::OnDatabaseError(int err, sql::Statement* stmt) { 1219 void AppCacheDatabase::OnDatabaseError(int err, sql::Statement* stmt) {
1220 was_corruption_detected_ |= sql::IsErrorCatastrophic(err); 1220 was_corruption_detected_ |= sql::IsErrorCatastrophic(err);
1221 if (!db_->ShouldIgnoreSqliteError(err)) 1221 if (!db_->ShouldIgnoreSqliteError(err))
1222 DLOG(ERROR) << db_->GetErrorMessage(); 1222 DLOG(ERROR) << db_->GetErrorMessage();
1223 // TODO: Maybe use non-catostrophic errors to trigger a full integrity check? 1223 // TODO: Maybe use non-catostrophic errors to trigger a full integrity check?
1224 } 1224 }
1225 1225
1226 } // namespace appcache 1226 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698