Bug 1398659. P11 - replace mCacheStream.GetLength() with GetLength(). r=gerald
authorJW Wang <jwwang@mozilla.com>
Fri, 08 Sep 2017 14:38:22 +0800
changeset 429494 fadb12f8f604e32db23b5e49beb1b55160a66c1a
parent 429493 665409f64b7083a98033e61b7191d4b68ccaf1e4
child 429495 130a5e787ba62b044dcc1150a2146286de9128ed
push id7761
push userjlund@mozilla.com
push dateFri, 15 Sep 2017 00:19:52 +0000
treeherdermozilla-beta@c38455951db4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgerald
bugs1398659
milestone57.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1398659. P11 - replace mCacheStream.GetLength() with GetLength(). r=gerald MozReview-Commit-ID: BGgObe2XG5C
dom/media/MediaResource.cpp
--- a/dom/media/MediaResource.cpp
+++ b/dom/media/MediaResource.cpp
@@ -743,17 +743,17 @@ void ChannelMediaResource::Resume()
     if (mChannel) {
       // Just wake up our existing channel
       mChannelStatistics.Start();
       // if an error occurs after Resume, assume it's because the server
       // timed out the connection and we should reopen it.
       mReopenOnError = true;
       element->DownloadResumed();
     } else {
-      int64_t totalLength = mCacheStream.GetLength();
+      int64_t totalLength = GetLength();
       // If mOffset is at the end of the stream, then we shouldn't try to
       // seek to it. The seek will fail and be wasted anyway. We can leave
       // the channel dead; if the media cache wants to read some other data
       // in the future, it will call CacheClientSeek itself which will reopen the
       // channel.
       if (totalLength < 0 || mOffset < totalLength) {
         // There is (or may be) data to read at mOffset, so start reading it.
         // Need to recreate the channel.