зеркало из https://github.com/mozilla/gecko-dev.git
015e4aa234
nsStyleImage::ComputeActualCropRect may return false under 4 conditions 1. mType is not eStyleImageType_Image. This function is design to be used when mType is eStyleImageType_Image. Replace this 'if' check by MOZ_ASSERT. 2. nsStyleImage::GetImageData() returns nullptr This function will return true if this image refers to a local-ref resource. 3. GetImage returns failure or does not return a valid imgIContainer. It's possible. Please refers to the comment in imgReqestProxy::GetImage at [1]. 4. imageSize is empty It's possible too. By giving a malformed image to a style image, we will hit this condition. And this is right what we met in this bug. Since ComputeActualCropRect may actaully return false, we should remove the NS_ASSERTION that assume it will always return true. [1] https://hg.mozilla.org/mozilla-central/file/7f1f1559cd8d/image/imgRequestProxy.cpp#l513 MozReview-Commit-ID: KHTFQJjiLtT --HG-- extra : rebase_source : c4e119dd250094115ab23c323ca49f9ebc296698 |
||
---|---|---|
.. | ||
background-common-usage-floating-point.html | ||
background-common-usage-percent.html | ||
background-common-usage-pixel.html | ||
background-common-usage-ref.html | ||
background-draw-nothing-empty-rect.html | ||
background-draw-nothing-invalid-syntax.html | ||
background-draw-nothing-malformed-images.html | ||
background-draw-nothing-ref.html | ||
background-monster-rect-ref.html | ||
background-monster-rect.html | ||
background-over-size-rect-ref.html | ||
background-over-size-rect.html | ||
background-test-parser-ref.html | ||
background-test-parser.html | ||
background-with-other-properties-ref.html | ||
background-with-other-properties.html | ||
background-zoom-1-ref.html | ||
background-zoom-1.html | ||
background-zoom-2-ref.html | ||
background-zoom-2.html | ||
background-zoom-3-ref.html | ||
background-zoom-3.html | ||
background-zoom-4-ref.html | ||
background-zoom-4.html | ||
dom-api-computed-style.html | ||
dom-api-ref.html | ||
dom-api.html | ||
green-16x16-in-blue-32x32.png | ||
reftest-stylo.list | ||
reftest.list | ||
transparent-16x16-in-blue-32x32.png |