Bug 1297580: P1. Remove broken optimisation in IntervalSet. r?gerald draft
authorJean-Yves Avenard <jyavenard@mozilla.com>
Wed, 24 Aug 2016 17:17:25 +1200
changeset 405244 d94f28ef0418537e6df5be512abf8cca741090d7
parent 405243 28be5d50a62408443ff16b17f2e90c0d1f4d72bd
child 405245 de89c070188423990b1a01aad7a5f2b392acae9a
push id27443
push userbmo:jyavenard@mozilla.com
push dateThu, 25 Aug 2016 04:44:40 +0000
reviewersgerald
bugs1297580
milestone51.0a1
Bug 1297580: P1. Remove broken optimisation in IntervalSet. r?gerald Interval.LeftOf would always return true if the length of the interval is less than the fuzzing value. MozReview-Commit-ID: L9uyZjQXnGA
dom/media/Intervals.h
--- a/dom/media/Intervals.h
+++ b/dom/media/Intervals.h
@@ -569,20 +569,16 @@ public:
       return mIntervals[aIndex].mEnd;
     } else {
       return T();
     }
   }
 
   bool Contains(const ElemType& aInterval) const {
     for (const auto& interval : mIntervals) {
-      if (aInterval.LeftOf(interval)) {
-        // Will never succeed.
-        return false;
-      }
       if (interval.Contains(aInterval)) {
         return true;
       }
     }
     return false;
   }
 
   bool Contains(const T& aX) const {