mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-16 23:05:42 +00:00
Bug 842463 - Prevent crash when feImage is not in a document. r=dzbarsky.
This commit is contained in:
parent
2386db5500
commit
054836f817
16
content/svg/content/src/crashtests/842463-1.html
Normal file
16
content/svg/content/src/crashtests/842463-1.html
Normal file
@ -0,0 +1,16 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<script>
|
||||
|
||||
function boom()
|
||||
{
|
||||
var f = document.createElementNS("http://www.w3.org/2000/svg", "feImage");
|
||||
f.setAttributeNS("http://www.w3.org/1999/xlink", "xlink:href", "#s");
|
||||
}
|
||||
|
||||
</script>
|
||||
</head>
|
||||
<body onload="boom();"></body>
|
||||
</html>
|
||||
|
@ -63,3 +63,5 @@ load 751515-1.svg
|
||||
load 761507-1.svg
|
||||
load 831561.html
|
||||
load 837450-1.svg
|
||||
load 842463-1.html
|
||||
|
||||
|
@ -5753,7 +5753,7 @@ nsSVGFEImageElement::Notify(imgIRequest* aRequest, int32_t aType, const nsIntRec
|
||||
void
|
||||
nsSVGFEImageElement::Invalidate()
|
||||
{
|
||||
if (GetParent()->IsSVG(nsGkAtoms::filter)) {
|
||||
if (GetParent() && GetParent()->IsSVG(nsGkAtoms::filter)) {
|
||||
static_cast<SVGFilterElement*>(GetParent())->Invalidate();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user