[php-src] PR #25428: ext/standard: Initialize $errno for unknown transport in stream_socket_client()/fsockopen()
| From: | jorgsowa | Date: | Thu, 12 Nov 2026 17:04:34 +0000 |
| Subject: | [php-src] PR #25428: ext/standard: Initialize $errno for unknown transport in stream_socket_client()/fsockopen() | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-40592@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/25428
Author: jorgsowa
For an unknown transport (e.g. bogus://host),
php_stream_xport_create() returns without
setting the error code, so stream_socket_client() and fsockopen() return
an uninitialized $errno instead of 0. Initialize err to 0, as
stream_socket_server() already does, and check $errno in tests.
Regression in PHP 8.6.