HTTPBodyStream in NSURLRequest gets lost when using CFNetwork loader
authorpsolanki@apple.com <psolanki@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 23 Oct 2011 05:03:19 +0000 (05:03 +0000)
committerpsolanki@apple.com <psolanki@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 23 Oct 2011 05:03:19 +0000 (05:03 +0000)
commit6e4353cf4ffc7d19f3c4524b9bc7077bb7215186
treef76b7fd2b8a4c9d62867d03f15532aa7086f66d9
parent9077f7683e2d73d00a78df7647396ef7a0c534fa
HTTPBodyStream in NSURLRequest gets lost when using CFNetwork loader
https://bugs.webkit.org/show_bug.cgi?id=70583
<rdar://problem/10281227>

Reviewed by Darin Adler.

Call WebCore::setHTTPBody() only if we actually have a FormData. Unconditionally calling it
results in us passing 0 to wkCFURLRequestSetHTTPRequestBodyParts() which resets any input
stream specified by the user on the NSURLRequest. This code matches the behavior in the
Foundation version of doUpdatePlatformRequest().

* platform/network/cf/ResourceRequestCFNet.cpp:
(WebCore::ResourceRequest::doUpdatePlatformRequest):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@98198 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp