зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1486562 - Record reference count changes for SourceListener, r=jib.
--HG-- extra : rebase_source : efd7935de09e85e15d6bd77fd65a49c42be7ff6f
This commit is contained in:
Родитель
8b21da2df9
Коммит
44f3ddf9d7
|
@ -342,7 +342,8 @@ public:
|
|||
typedef MozPromise<bool /* aIgnored */, RefPtr<MediaMgrError>, true> InitPromise;
|
||||
|
||||
MOZ_DECLARE_WEAKREFERENCE_TYPENAME(SourceListener)
|
||||
NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(SourceListener)
|
||||
NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION_AND_RECORDING(SourceListener,
|
||||
recordreplay::Behavior::Preserve)
|
||||
|
||||
SourceListener();
|
||||
|
||||
|
|
|
@ -59,7 +59,7 @@ struct DeleteOnMainThreadTask : public Runnable
|
|||
} // namespace layers
|
||||
} // namespace mozilla
|
||||
|
||||
#define NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(_class) \
|
||||
#define NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION_AND_RECORDING(_class, _recording) \
|
||||
public: \
|
||||
NS_METHOD_(MozExternalRefCountType) AddRef(void) { \
|
||||
MOZ_ASSERT_TYPE_OK_FOR_REFCOUNTING(_class) \
|
||||
|
@ -89,9 +89,13 @@ public: \
|
|||
return count; \
|
||||
} \
|
||||
protected: \
|
||||
::mozilla::ThreadSafeAutoRefCnt mRefCnt; \
|
||||
::mozilla::ThreadSafeAutoRefCntWithRecording<_recording> mRefCnt; \
|
||||
private: \
|
||||
::mozilla::layers::HelperForMainThreadDestruction mHelperForMainThreadDestruction; \
|
||||
public:
|
||||
|
||||
#define NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION(_class) \
|
||||
NS_INLINE_DECL_THREADSAFE_REFCOUNTING_WITH_MAIN_THREAD_DESTRUCTION_AND_RECORDING \
|
||||
(_class, recordreplay::Behavior::DontPreserve)
|
||||
|
||||
#endif
|
||||
|
|
Загрузка…
Ссылка в новой задаче