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

Unified Diff: content/renderer/media/buffered_data_source.h

Issue 193303002: WeakPtr destruction order cleanup: media edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 6 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: content/renderer/media/buffered_data_source.h
diff --git a/content/renderer/media/buffered_data_source.h b/content/renderer/media/buffered_data_source.h
index 30991dd2796f16b2a670119f7d40bce47e820e14..40e549d900f7cb0688c280c797c6446890ab7358 100644
--- a/content/renderer/media/buffered_data_source.h
+++ b/content/renderer/media/buffered_data_source.h
@@ -139,8 +139,6 @@ class CONTENT_EXPORT BufferedDataSource : public media::DataSource {
// change in playback rate.
void UpdateDeferStrategy(bool paused);
- base::WeakPtr<BufferedDataSource> weak_this_;
-
// URL of the resource requested.
GURL url_;
// crossorigin attribute on the corresponding HTML media element, if any.
@@ -216,6 +214,7 @@ class CONTENT_EXPORT BufferedDataSource : public media::DataSource {
DownloadingCB downloading_cb_;
+ // NOTE: Weak pointers must be invalidated before all other member variables.
base::WeakPtrFactory<BufferedDataSource> weak_factory_;
DISALLOW_COPY_AND_ASSIGN(BufferedDataSource);
« no previous file with comments | « content/renderer/media/android/webmediaplayer_android.h ('k') | content/renderer/media/buffered_data_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698