Commit bb09dcd6 authored by Victor Costan's avatar Victor Costan Committed by Commit Bot

DOM Storage: Remove unused SQLite migration code.

Change-Id: I3673a9a4411c00b72a3e96b405ce726c9632ca4a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2359235
Commit-Queue: Victor Costan <pwnall@chromium.org>
Auto-Submit: Victor Costan <pwnall@chromium.org>
Reviewed-by: default avatarMarijn Kruisselbrink <mek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#798825}
parent 56fdaa91
......@@ -18,9 +18,7 @@ LegacyDomStorageDatabase::LegacyDomStorageDatabase(
const base::FilePath& file_path,
std::unique_ptr<FilesystemProxy> filesystem_proxy)
: file_path_(file_path), filesystem_proxy_(std::move(filesystem_proxy)) {
// Note: in normal use we should never get an empty backing path here.
// However, the unit test for this class can contruct an instance
// with an empty path.
DCHECK(!file_path_.empty());
Init();
}
......@@ -167,14 +165,6 @@ bool LegacyDomStorageDatabase::LazyOpen(bool create_if_needed) {
// (tiny amount of) problems that mmap() may cause.
db_->set_mmap_disabled();
if (file_path_.empty()) {
// This code path should only be triggered by unit tests.
if (!db_->OpenInMemory()) {
NOTREACHED() << "Unable to open DOM storage database in memory.";
failed_to_open_ = true;
return false;
}
} else {
if (!db_->Open(file_path_)) {
LOG(ERROR) << "Unable to open DOM storage database at "
<< file_path_.value() << " error: " << db_->GetErrorMessage();
......@@ -183,7 +173,6 @@ bool LegacyDomStorageDatabase::LazyOpen(bool create_if_needed) {
failed_to_open_ = true;
return false;
}
}
// sql::Database uses UTF-8 encoding, but WebCore style databases use
// UTF-16, so ensure we match.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment