Loading xpcom/ds/nsTArray.h +3 −0 Original line number Diff line number Diff line Loading @@ -2461,6 +2461,9 @@ auto nsTArray_Impl<E, Alloc>::ReplaceElementsAtInternal(index_type aStart, if (MOZ_UNLIKELY(aStart > Length())) { InvalidArrayIndex_CRASH(aStart, Length()); } if (MOZ_UNLIKELY(aCount > Length() - aStart)) { InvalidArrayIndex_CRASH(aStart + aCount, Length()); } // Adjust memory allocation up-front to catch errors. if (!ActualAlloc::Successful(this->template EnsureCapacity<ActualAlloc>( Loading Loading
xpcom/ds/nsTArray.h +3 −0 Original line number Diff line number Diff line Loading @@ -2461,6 +2461,9 @@ auto nsTArray_Impl<E, Alloc>::ReplaceElementsAtInternal(index_type aStart, if (MOZ_UNLIKELY(aStart > Length())) { InvalidArrayIndex_CRASH(aStart, Length()); } if (MOZ_UNLIKELY(aCount > Length() - aStart)) { InvalidArrayIndex_CRASH(aStart + aCount, Length()); } // Adjust memory allocation up-front to catch errors. if (!ActualAlloc::Successful(this->template EnsureCapacity<ActualAlloc>( Loading