2011-03-16 Pratik Solanki <psolanki@apple.com>
authorpsolanki@apple.com <psolanki@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 16 Mar 2011 19:28:55 +0000 (19:28 +0000)
committerpsolanki@apple.com <psolanki@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 16 Mar 2011 19:28:55 +0000 (19:28 +0000)
commitc524ca6fb8e386846700e6fa2281270d3b429cbb
treec7e46fcc06d7df05f2111b58ff1e971036d7a1bf
parent42c967a17c09ecf5b6da8dce71b001deed46b325
2011-03-16  Pratik Solanki  <psolanki@apple.com>

        Reviewed by Alexey Proskuryakov.

        REGRESSION: Crash in adjustMIMETypeIfNecessary since r81001
        https://bugs.webkit.org/show_bug.cgi?id=56345

        Add test that verifies the we don't crash when an XHR response headers don't contain
        Content-Type.

        * http/tests/xmlhttprequest/resources/.htaccess:
        * http/tests/xmlhttprequest/resources/noContentType.asis: Added.
        * http/tests/xmlhttprequest/xmlhttprequest-no-content-type-expected.txt: Added.
        * http/tests/xmlhttprequest/xmlhttprequest-no-content-type.html: Added.
2011-03-16  Pratik Solanki  <psolanki@apple.com>

        Reviewed by Alexey Proskuryakov.

        REGRESSION: Crash in adjustMIMETypeIfNecessary since r81001
        https://bugs.webkit.org/show_bug.cgi?id=56345

        Add NULL check for Content-Type header field.

        Test: http/tests/xmlhttprequest/xmlhttprequest-no-content-type.html

        * platform/network/mac/WebCoreURLResponse.mm:
        (WebCore::adjustMIMETypeIfNecessary):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@81267 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/http/tests/xmlhttprequest/resources/.htaccess
LayoutTests/http/tests/xmlhttprequest/resources/noContentType.asis [new file with mode: 0644]
LayoutTests/http/tests/xmlhttprequest/xmlhttprequest-no-content-type-expected.txt [new file with mode: 0644]
LayoutTests/http/tests/xmlhttprequest/xmlhttprequest-no-content-type.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/platform/network/mac/WebCoreURLResponse.mm