Filename passed to FormData.append() takes precedence over filename in
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 4 Mar 2013 22:28:11 +0000 (22:28 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 4 Mar 2013 22:28:11 +0000 (22:28 +0000)
commit383d418798ff150150371d5e65592fbda8e8df92
treea883a60a2f6c69432773f693f4fb136be4aa5be3
parentf50b32f6eb788b64750d2f2b92e97ea1db95ad40
Filename passed to FormData.append() takes precedence over filename in
File.
https://bugs.webkit.org/show_bug.cgi?id=111255

Patch by Victor Costan <costan@gmail.com> on 2013-03-04
Reviewed by Alexey Proskuryakov.

Source/WebCore:

Test: http/tests/local/formdata/send-form-data-with-filename.html

* platform/network/FormData.cpp:
(WebCore::FormData::appendKeyValuePairItems): changed to implement the
behavior in the XMLHttpRequest W3C spec.

LayoutTests:

(runTest):
* http/tests/local/formdata/send-form-data-with-filename-expected.txt: Added.
* http/tests/local/formdata/send-form-data-with-filename.html: Added.
* http/tests/local/formdata/send-form-data-with-sliced-file-expected.txt: Updated
to reflect the behavior specified in the XMLHttpRequest W3C spec.
* platform/wk2/TestExpectations: newly added test doesn't work in
WebKit2 because beginDragWithFiles is not implemented

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@144677 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/http/tests/local/formdata/send-form-data-with-filename-expected.txt [new file with mode: 0644]
LayoutTests/http/tests/local/formdata/send-form-data-with-filename.html [new file with mode: 0644]
LayoutTests/http/tests/local/formdata/send-form-data-with-sliced-file-expected.txt
LayoutTests/platform/wk2/TestExpectations
Source/WebCore/ChangeLog
Source/WebCore/platform/network/FormData.cpp