diff --git a/src/Http.php b/src/Http.php index 6f7ed52..86a071c 100644 --- a/src/Http.php +++ b/src/Http.php @@ -385,7 +385,7 @@ public static function decode(string $recv_buffer, TcpConnection $connection): v case 'HOST': $tmp = \explode(':', $value); $_SERVER['SERVER_NAME'] = $tmp[0]; - $_SERVER['SERVER_PORT'] = $tmp[1] ?? 80; + $_SERVER['SERVER_PORT'] = (int) ($tmp[1] ?? 80); break; // cookie case 'COOKIE':