[8.0] Update EasyHandle in order to avoid bad writes of properties related to the handle#2293
[8.0] Update EasyHandle in order to avoid bad writes of properties related to the handle#2293phansys wants to merge 1 commit intoguzzle:8.0from
EasyHandle in order to avoid bad writes of properties related to the handle#2293Conversation
9ff0a64 to
a1d7847
Compare
|
Thank you for the PR. |
|
The prevention is done in order to avoid the object to accept a set of inconsistent values, regardless who is writing them. In my specific use case, the situation was caused from a 3rd party library using Guzzle, but I don't have enough details since I think the problem was related to #2292. |
0975ccd to
c782faf
Compare
| // Retry when nothing is present or when curl failed to rewind. | ||
| if (empty($easy->options['_err_message']) | ||
| && (!$easy->errno || $easy->errno == 65) | ||
| && (!$easy->errno || $easy->errno == /* CURLE_SEND_FAIL_REWIND */ 65) |
There was a problem hiding this comment.
When is this constant not set? Was added at least 10 years ago, wasn't it?
There was a problem hiding this comment.
Oh, I see. They never made it into PHP-land. ;)
7f8c70a to
0998eab
Compare
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed after 2 weeks if no further activity occurs. Thank you for your contributions. |
8e43093 to
dd0ea36
Compare
2a25470 to
36c07f3
Compare
EasyHandle in order to avoid bad writes of properties related to the handleEasyHandle in order to avoid bad writes of properties related to the handle
|
@phansys are you able to resolve the merge conflicts please? |
c14b88a to
229317f
Compare
Since this PR is almost 5 years old, I guess I must also update the behavior on some checks, since the added support for PHP >= 8 in the target branch also changed some return values in CURL functions (like |
ed9dfc1 to
2245ac1
Compare
| } | ||
|
|
||
| /** | ||
| * @throws \LogicException |
There was a problem hiding this comment.
Where does it throw LogicException in __unset?
There was a problem hiding this comment.
This exception isn't thrown in the current implementation. The docblock was updated, thank you.
267b28b to
0e8c2ca
Compare
With these changes, setting fake values like this can be prevented.