| Index: storage/browser/quota/quota_database.cc
|
| diff --git a/storage/browser/quota/quota_database.cc b/storage/browser/quota/quota_database.cc
|
| index f1fefb6be401860b6356daff44f4e0fdf056427c..b11115c26096ad6d97f9eae4c754fb11b7331ae3 100644
|
| --- a/storage/browser/quota/quota_database.cc
|
| +++ b/storage/browser/quota/quota_database.cc
|
| @@ -286,7 +286,7 @@ bool QuotaDatabase::GetOriginLastEvictionTime(const GURL& origin,
|
| statement.BindInt(1, static_cast<int>(type));
|
|
|
| if (!statement.Step())
|
| - return statement.Succeeded();
|
| + return false;
|
|
|
| *last_modified_time = base::Time::FromInternalValue(statement.ColumnInt64(0));
|
| return true;
|
| @@ -357,6 +357,31 @@ bool QuotaDatabase::RegisterInitialOriginInfo(
|
| return true;
|
| }
|
|
|
| +bool QuotaDatabase::GetOriginInfo(const GURL& origin,
|
| + StorageType type,
|
| + QuotaDatabase::OriginInfoTableEntry* entry) {
|
| + if (!LazyOpen(false))
|
| + return false;
|
| +
|
| + const char* kSql =
|
| + "SELECT * FROM OriginInfoTable"
|
| + " WHERE origin = ? AND type = ?";
|
| + sql::Statement statement(db_->GetCachedStatement(SQL_FROM_HERE, kSql));
|
| + statement.BindString(0, origin.spec());
|
| + statement.BindInt(1, static_cast<int>(type));
|
| +
|
| + if (!statement.Step())
|
| + return false;
|
| +
|
| + *entry = OriginInfoTableEntry(
|
| + GURL(statement.ColumnString(0)),
|
| + static_cast<StorageType>(statement.ColumnInt(1)), statement.ColumnInt(2),
|
| + base::Time::FromInternalValue(statement.ColumnInt64(3)),
|
| + base::Time::FromInternalValue(statement.ColumnInt64(4)));
|
| +
|
| + return true;
|
| +}
|
| +
|
| bool QuotaDatabase::DeleteHostQuota(
|
| const std::string& host, StorageType type) {
|
| if (!LazyOpen(false))
|
|
|