diff --git a/layout/style/ServoBindings.cpp b/layout/style/ServoBindings.cpp index 5d0e472fad40..149cbeeae445 100644 --- a/layout/style/ServoBindings.cpp +++ b/layout/style/ServoBindings.cpp @@ -1091,6 +1091,10 @@ Gecko_NewCSSValueSharedList(uint32_t aLen) void Gecko_CSSValue_SetAbsoluteLength(nsCSSValueBorrowedMut aCSSValue, nscoord aLen) { + MOZ_ASSERT(aCSSValue->GetUnit() == eCSSUnit_Null || aCSSValue->IsLengthUnit()); + // The call below could trigger refcounting if aCSSValue were a + // FontFamilyList, but we just asserted that it's not. So we can + // whitelist this for static analysis. aCSSValue->SetIntegerCoordValue(aLen); }