From: Nikita Popov Date: Fri, 23 Oct 2020 09:46:54 +0000 (+0200) Subject: Fix pasv_port determination X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3859e743478cc7b1f47bfb40873ef9290b012ae5;p=php Fix pasv_port determination Apparently the ftp server is also used by ext/standard/tests/streams, and only that part actually uses pasv. --- diff --git a/ext/ftp/tests/server.inc b/ext/ftp/tests/server.inc index 33e32ac1bb..e220d6f072 100644 --- a/ext/ftp/tests/server.inc +++ b/ext/ftp/tests/server.inc @@ -407,7 +407,7 @@ if ($pid) { } $soc_name = stream_socket_get_name($soc, false); - $pasv_port = (int) substr($socket_name, strrpos($soc_name, ':') + 1); + $pasv_port = (int) substr($soc_name, strrpos($soc_name, ':') + 1); } else { $pasv_port = 1234; }