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

Unified Diff: storage/browser/blob/shareable_file_reference.h

Issue 1004593005: base::RefCounted now DCHECKs when referenced from multiple threads. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix lots of tests using UnsafeRefCounted. Created 5 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: storage/browser/blob/shareable_file_reference.h
diff --git a/storage/browser/blob/shareable_file_reference.h b/storage/browser/blob/shareable_file_reference.h
index e2739dcf8604654772991a11d14239c1c20cba23..2e0cad014b0655ddaf119fa2fc4c5000e3caa23d 100644
--- a/storage/browser/blob/shareable_file_reference.h
+++ b/storage/browser/blob/shareable_file_reference.h
@@ -16,8 +16,9 @@ namespace storage {
// same path if it already exists in its internal map.
// This class is non-thread-safe and all methods must be called on a single
// thread.
+// TODO(mgiuca): Avoid using UnsafeRefCounted. http://crbug.com/469952.
class STORAGE_EXPORT ShareableFileReference
- : public base::RefCounted<ShareableFileReference> {
+ : public base::UnsafeRefCounted<ShareableFileReference> {
public:
typedef ScopedFile::ScopeOutCallback FinalReleaseCallback;
@@ -60,7 +61,7 @@ class STORAGE_EXPORT ShareableFileReference
void AddFinalReleaseCallback(const FinalReleaseCallback& callback);
private:
- friend class base::RefCounted<ShareableFileReference>;
+ friend class base::UnsafeRefCounted<ShareableFileReference>;
ShareableFileReference(ScopedFile scoped_file);
~ShareableFileReference();
« base/memory/ref_counted.h ('K') | « sql/connection.h ('k') | ui/gfx/image/image.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698