2011-04-26 Leo Yang <leo.yang@torchmobile.com.cn>
authorleo.yang@torchmobile.com.cn <leo.yang@torchmobile.com.cn@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 26 Apr 2011 09:57:11 +0000 (09:57 +0000)
committerleo.yang@torchmobile.com.cn <leo.yang@torchmobile.com.cn@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 26 Apr 2011 09:57:11 +0000 (09:57 +0000)
commit48e3aa958ff22c2bdfddf884c602e2e66be94cbc
treed05ab759df5a89ac0a61a3607c7bc1dda5fd8fbe
parentbff477fd4ad7c3ab7ce2cde754eb04a72e7a06f1
2011-04-26  Leo Yang  <leo.yang@torchmobile.com.cn>

        Reviewed by Nikolas Zimmermann.

        ASSERT failure in SVGUseElement
        https://bugs.webkit.org/show_bug.cgi?id=59313

        Test case to verify webkit doesn't crash when a <use> element
        is pending on resource and the document is not well-formed.
        Test passes if no crash occurs in debug mode.

        * svg/custom/use-crash-in-non-wellformed-document-expected.txt: Added.
        * svg/custom/use-crash-in-non-wellformed-document.svg: Added.
2011-04-26  Leo Yang  <leo.yang@torchmobile.com.cn>

        Reviewed by Nikolas Zimmermann.

        ASSERT failure in SVGUseElement
        https://bugs.webkit.org/show_bug.cgi?id=59313

        In SVGUseElement::insertedIntoDocument(), ASSERT(!m_isPendingResource)
        was wrong because the document may not be well-formed.

        This patch asserts the element is not pending on resource or the
        document is not well-formed.

        Test: svg/custom/use-crash-in-non-wellformed-document.svg

        * svg/SVGUseElement.cpp:
        (WebCore::isWellFormedDocument):
        (WebCore::SVGUseElement::insertedIntoDocument):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@84899 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/svg/custom/use-crash-in-non-wellformed-document-expected.txt [new file with mode: 0644]
LayoutTests/svg/custom/use-crash-in-non-wellformed-document.svg [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/svg/SVGUseElement.cpp