WordPress / WordPress/Requests
cURL fails when `mbstring.func_overload` is set
Open
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 3.6k
- Forks
- 500
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 5
Description
As reported to WordPress in #38226:
cURL error 23: Failed writing body (624 != 811)
Apparently it happens if
mbstring.func_overloadis enabled and body length is calculated incorrectly.
The cURL transport doesn't operate on binary strings when mbstring.func_overload is enabled.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the cURL transport failure with mbstring.func_overload enabled and inspect how the transport calculates and writes the response body. Done means binary response bodies are written successfully without the reported cURL error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100