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
commitc1cfd11d6abd13cb7868e510007c8d25be6096ec (patch)
tree95d4ad6a2fb0d4dc1d2aee1cc4a2f834114abffc /dom
parent66fae1d81013a2321e7d607a426f834a01b847ce (diff)
downloaduxp-c1cfd11d6abd13cb7868e510007c8d25be6096ec.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;