build connection url to parse ipv6 #72811

This commit is contained in:
yggverse 2024-04-28 02:55:14 +03:00
parent b06f5c5e97
commit 817347ebbb

View File

@ -314,6 +314,12 @@ $server->start(
// Dump request on enabled // Dump request on enabled
if (NEXT_DUMP) if (NEXT_DUMP)
{ {
// Build connection URL #72811
$url = sprintf(
'nex://%s',
$connect
);
printf( printf(
str_ireplace( str_ireplace(
[ [
@ -327,8 +333,8 @@ $server->start(
[ [
(string) date('c'), (string) date('c'),
(string) (int) !empty($response), (string) (int) !empty($response),
(string) parse_url($connect, PHP_URL_HOST), (string) parse_url($url, PHP_URL_HOST),
(string) parse_url($connect, PHP_URL_PORT), (string) parse_url($url, PHP_URL_PORT),
(string) str_replace('%', '%%', empty($request) ? '/' : $request), (string) str_replace('%', '%%', empty($request) ? '/' : $request),
(string) str_replace('%', '%%', $realpath) (string) str_replace('%', '%%', $realpath)
], ],