Bug 1138557 - Add null check to mLoadingSrc. r=karlt, a=lmandel
authorJW Wang <jwwang@mozilla.com>
Tue, 03 Mar 2015 02:14:00 -0500
changeset 250305 58b004077c10
parent 250304 8746f7ba56c9
child 250306 5d0326e1f387
push id4541
push userryanvm@gmail.com
push date2015-03-09 19:01 +0000
treeherdermozilla-beta@58b004077c10 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskarlt, lmandel
bugs1138557
milestone37.0
Bug 1138557 - Add null check to mLoadingSrc. r=karlt, a=lmandel
dom/html/HTMLMediaElement.cpp
--- a/dom/html/HTMLMediaElement.cpp
+++ b/dom/html/HTMLMediaElement.cpp
@@ -3258,17 +3258,17 @@ void HTMLMediaElement::CheckProgress(boo
         ChangeDelayLoadStatus(true);
       }
     }
   }
 
   if (now - mDataTime >= TimeDuration::FromMilliseconds(STALL_MS)) {
     DispatchAsyncEvent(NS_LITERAL_STRING("stalled"));
 
-    if (IsMediaSourceURI(mLoadingSrc)) {
+    if (mLoadingSrc && IsMediaSourceURI(mLoadingSrc)) {
       ChangeDelayLoadStatus(false);
     }
 
     NS_ASSERTION(mProgressTimer, "detected stalled without timer");
     // Stop timer events, which prevents repeated stalled events until there
     // is more progress.
     StopProgress();
   }