summaryrefslogtreecommitdiff
path: root/dom
diff options
context:
space:
mode:
authorBryce Van Dyk <bvandyk@mozilla.com>2019-07-18 18:10:14 +0200
committerwolfbeast <mcwerewolf@wolfbeast.com>2019-07-18 18:10:14 +0200
commitb8c3eb85e636eb79bf7a81587fb8a61ad707ca07 (patch)
tree95d4ad6a2fb0d4dc1d2aee1cc4a2f834114abffc /dom
parent3f9262dba49bc538f4fd88c7e02d4f938d2ab4bf (diff)
downloaduxp-b8c3eb85e636eb79bf7a81587fb8a61ad707ca07.tar.gz
Use a RefPtr to hold owner element ref when moving media resource load
to background.
Diffstat (limited to 'dom')
-rw-r--r--dom/media/MediaResource.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/dom/media/MediaResource.cpp b/dom/media/MediaResource.cpp
index d36783be7c..84a8d67fd9 100644
--- a/dom/media/MediaResource.cpp
+++ b/dom/media/MediaResource.cpp
@@ -1525,7 +1525,7 @@ void BaseMediaResource::SetLoadInBackground(bool aLoadInBackground) {
NS_WARNING("Null owner in MediaResource::SetLoadInBackground()");
return;
}
- dom::HTMLMediaElement* element = owner->GetMediaElement();
+ RefPtr<dom::HTMLMediaElement> element = owner->GetMediaElement();
if (!element) {
NS_WARNING("Null element in MediaResource::SetLoadInBackground()");
return;