You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bug #59727 [HttpClient] Fix activity tracking leading to negative timeout errors (nicolas-grekas)
This PR was merged into the 6.4 branch.
Discussion
----------
[HttpClient] Fix activity tracking leading to negative timeout errors
| Q | A
| ------------- | ---
| Branch? | 6.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Issues | Fix#59041
| License | MIT
The error case leading to the linked issue is very hard to spot. I won't be able to provide a reproducer nor am I 100% sure that this will fix it. This patch comes solely from logical reasoning so I might have missed something, but hopefully this closes any possibility of passing a negative timeout to `self::select()`.
The fix should be provided by the changed lines about `$hasActivity` and `$lastActivity`.
The rest is cleaning / hardening found meanwhile.
Commits
-------
ee3451b [HttpClient] Fix activity tracking leading to negative timeout errors
$multi->handlesActivity[(int) $response->handle][] = newTransportException(sprintf('Userland callback cannot use the client nor the response while processing "%s".', curl_getinfo($response->handle, \CURLINFO_EFFECTIVE_URL)));
0 commit comments