From 0cff1326a24f58e4b67f2e8a54756667db76332a Mon Sep 17 00:00:00 2001 From: deuce <> Date: Fri, 10 Apr 2020 06:56:46 +0000 Subject: [PATCH] Support response code 120 (expected delay) during connection. --- exec/load/ftp.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/exec/load/ftp.js b/exec/load/ftp.js index 6ce8d9495a..85ccda7054 100644 --- a/exec/load/ftp.js +++ b/exec/load/ftp.js @@ -32,6 +32,10 @@ function FTP(host, user, pass, port, dport, bindhost, account) this.account = account; this.socket = new ConnectedSocket(host, port, {protocol:'FTP', timeout:this.timeout, binadaddrs:this.bindhost}); var response = this.cmd(undefined, true); + if (parseInt(response, 10) !== 120) { + log(LOG_NOTICE, "Connection delay: "+response); + response = this.cmd(undefined, true); + } if (parseInt(response, 10) !== 220) { this.socket.close(); throw("Invalid response from server: " + response); -- GitLab