Closed rcanavan closed 7 years ago
Works for me(tm). IIRC, this is fixed in newer PHP versions. No warning here with PHP-7.1.2 locally.
Hah, the warning's just been put in the error log.
Could you try the following patch, please? issue65.txt
No warning here with PHP-7.1.2 locally.
I'm using PHP 7.1.3. Today the errors appear to be more or less permanent, and only a restart of PHP-FPM allows me to process requests with the "broken" persistent handle. With the patch, no warnings are printed and all requests are apparently handled successfully.
Awesome, thank you!
If one attempts to exit() a PHP program from within the setDebug() callback of a http\Client, a Warning is emitted:
If the Client uses a persistent handle, enqueuing a new request, even from a subsequent incoming client request in the same PHP / PHP-FPM child, this fails with a fatal error:
Test program:
The obvious solution is not to use exit() in the debug callback, but there may be more legitimate ways to trigger this. To trigger the problem, it may be necessary to call the test program above in a tight loop, e.g.