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

Unified Diff: base/memory/ref_counted.h

Issue 1749053002: Move //remoting/remoting_host_win.gypi:* to GN (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update for component build of Windows Created 4 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
« no previous file with comments | « no previous file | base/memory/ref_counted.cc » ('j') | remoting/host/BUILD.gn » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/memory/ref_counted.h
diff --git a/base/memory/ref_counted.h b/base/memory/ref_counted.h
index e73951481be0e5501ae2bdc73c56502d3d51d7b9..1ebaa51ad42e6d4e08588d49e99200a1501b16ff 100644
--- a/base/memory/ref_counted.h
+++ b/base/memory/ref_counted.h
@@ -42,34 +42,10 @@ class BASE_EXPORT RefCountedBase {
}
- void AddRef() const {
- // TODO(maruel): Add back once it doesn't assert 500 times/sec.
- // Current thread books the critical section "AddRelease"
- // without release it.
- // DFAKE_SCOPED_LOCK_THREAD_LOCKED(add_release_);
- #ifndef NDEBUG
- DCHECK(!in_dtor_);
- #endif
- ++ref_count_;
- }
+ void AddRef() const;
// Returns true if the object should self-delete.
- bool Release() const {
- // TODO(maruel): Add back once it doesn't assert 500 times/sec.
- // Current thread books the critical section "AddRelease"
- // without release it.
- // DFAKE_SCOPED_LOCK_THREAD_LOCKED(add_release_);
- #ifndef NDEBUG
- DCHECK(!in_dtor_);
- #endif
- if (--ref_count_ == 0) {
- #ifndef NDEBUG
- in_dtor_ = true;
- #endif
- return true;
- }
- return false;
- }
+ bool Release() const;
private:
mutable int ref_count_;
« no previous file with comments | « no previous file | base/memory/ref_counted.cc » ('j') | remoting/host/BUILD.gn » ('J')

Powered by Google App Engine
This is Rietveld 408576698