diff options
author | Bryce Van Dyk <bvandyk@mozilla.com> | 2019-07-18 18:10:14 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@wolfbeast.com> | 2019-07-18 18:10:14 +0200 |
commit | c1cfd11d6abd13cb7868e510007c8d25be6096ec (patch) | |
tree | 95d4ad6a2fb0d4dc1d2aee1cc4a2f834114abffc | |
parent | 66fae1d81013a2321e7d607a426f834a01b847ce (diff) | |
download | UXP-c1cfd11d6abd13cb7868e510007c8d25be6096ec.tar UXP-c1cfd11d6abd13cb7868e510007c8d25be6096ec.tar.gz UXP-c1cfd11d6abd13cb7868e510007c8d25be6096ec.tar.lz UXP-c1cfd11d6abd13cb7868e510007c8d25be6096ec.tar.xz UXP-c1cfd11d6abd13cb7868e510007c8d25be6096ec.zip |
Use a RefPtr to hold owner element ref when moving media resource load
to background.
-rw-r--r-- | dom/media/MediaResource.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dom/media/MediaResource.cpp b/dom/media/MediaResource.cpp index d36783be7..84a8d67fd 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; |