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

Side by Side Diff: content/browser/indexed_db/indexed_db_fake_backing_store.cc

Issue 417573004: indexeddb: Removed use of dangling ptr in writeBlobToFileOnIOThread. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Also scoped LocalWriteClosure::task_runner_ 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/indexed_db/indexed_db_fake_backing_store.h" 5 #include "content/browser/indexed_db/indexed_db_fake_backing_store.h"
6 6
7 #include "base/files/file_path.h" 7 #include "base/files/file_path.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 9
10 namespace content { 10 namespace content {
11 11
12 IndexedDBFakeBackingStore::IndexedDBFakeBackingStore() 12 IndexedDBFakeBackingStore::IndexedDBFakeBackingStore()
13 : IndexedDBBackingStore(NULL /* indexed_db_factory */, 13 : IndexedDBBackingStore(NULL /* indexed_db_factory */,
14 GURL("http://localhost:81"), 14 GURL("http://localhost:81"),
15 base::FilePath(), 15 base::FilePath(),
16 NULL /* request_context */, 16 NULL /* request_context */,
17 scoped_ptr<LevelDBDatabase>(), 17 scoped_ptr<LevelDBDatabase>(),
18 scoped_ptr<LevelDBComparator>(), 18 scoped_ptr<LevelDBComparator>(),
19 NULL /* task_runner */) { 19 NULL /* task_runner */) {
20 } 20 }
21 IndexedDBFakeBackingStore::IndexedDBFakeBackingStore( 21 IndexedDBFakeBackingStore::IndexedDBFakeBackingStore(
22 IndexedDBFactory* factory, 22 IndexedDBFactory* factory,
23 base::TaskRunner* task_runner) 23 base::SequencedTaskRunner* task_runner)
24 : IndexedDBBackingStore(factory, 24 : IndexedDBBackingStore(factory,
25 GURL("http://localhost:81"), 25 GURL("http://localhost:81"),
26 base::FilePath(), 26 base::FilePath(),
27 NULL /* request_context */, 27 NULL /* request_context */,
28 scoped_ptr<LevelDBDatabase>(), 28 scoped_ptr<LevelDBDatabase>(),
29 scoped_ptr<LevelDBComparator>(), 29 scoped_ptr<LevelDBComparator>(),
30 task_runner) { 30 task_runner) {
31 } 31 }
32 IndexedDBFakeBackingStore::~IndexedDBFakeBackingStore() {} 32 IndexedDBFakeBackingStore::~IndexedDBFakeBackingStore() {}
33 33
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
209 scoped_refptr<BlobWriteCallback> callback) { 209 scoped_refptr<BlobWriteCallback> callback) {
210 callback->Run(true); 210 callback->Run(true);
211 return leveldb::Status::OK(); 211 return leveldb::Status::OK();
212 } 212 }
213 leveldb::Status IndexedDBFakeBackingStore::FakeTransaction::CommitPhaseTwo() { 213 leveldb::Status IndexedDBFakeBackingStore::FakeTransaction::CommitPhaseTwo() {
214 return result_; 214 return result_;
215 } 215 }
216 void IndexedDBFakeBackingStore::FakeTransaction::Rollback() {} 216 void IndexedDBFakeBackingStore::FakeTransaction::Rollback() {}
217 217
218 } // namespace content 218 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/indexed_db/indexed_db_fake_backing_store.h ('k') | content/public/browser/indexed_db_context.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698