Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit c8dbd1a

Browse filesBrowse files
bug #33727 [HttpClient] workaround bad Content-Length sent by old libcurl (nicolas-grekas)
This PR was merged into the 4.3 branch. Discussion ---------- [HttpClient] workaround bad Content-Length sent by old libcurl | Q | A | ------------- | --- | Branch? | 4.3 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | - | License | MIT | Doc PR | - Issue described in https://curl.haxx.se/mail/lib-2014-01/0106.html, happens with curl 7.29 at least. Commits ------- b8d2496 [HttpClient] workaround bad Content-Length sent by old libcurl
2 parents 0d05f3e + b8d2496 commit c8dbd1a
Copy full SHA for c8dbd1a

File tree

1 file changed

+1
-1
lines changed
Filter options

1 file changed

+1
-1
lines changed

‎src/Symfony/Component/HttpClient/CurlHttpClient.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/HttpClient/CurlHttpClient.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ public function request(string $method, string $url, array $options = []): Respo
245245
if ('POST' !== $method) {
246246
$curlopts[CURLOPT_UPLOAD] = true;
247247
}
248-
} elseif ('' !== $body) {
248+
} elseif ('' !== $body || 'POST' === $method) {
249249
$curlopts[CURLOPT_POSTFIELDS] = $body;
250250
}
251251

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.