diff --git a/WHATSNEW b/WHATSNEW index b515bea72..f5fcc4fa1 100644 --- a/WHATSNEW +++ b/WHATSNEW @@ -18,6 +18,8 @@ Changes that could break older environments: Fixed bugs: ----------- +* Fixed bug where ant would not perform ftp without remotedir being + specified even though this was not mandatory. * Fixed bug where ant would not copy system properties into new Project in ant/antcall tasks when inheritall="false" is set. diff --git a/src/main/org/apache/tools/ant/taskdefs/optional/net/FTP.java b/src/main/org/apache/tools/ant/taskdefs/optional/net/FTP.java index cd9c310a9..c21ee0f85 100644 --- a/src/main/org/apache/tools/ant/taskdefs/optional/net/FTP.java +++ b/src/main/org/apache/tools/ant/taskdefs/optional/net/FTP.java @@ -603,7 +603,7 @@ public class FTP FTPFile[] files = ftp.listFiles(remoteFile); - // For Microsoft's Ftp-Service an Array with length 0 is + // For Microsoft's Ftp-Service an Array with length 0 is // returned if configured to return listings in "MS-DOS"-Format if (files == null || files.length == 0) { @@ -916,10 +916,9 @@ public class FTP "could not change remote directory: " + ftp.getReplyString()); } - - log(ACTION_STRS[action] + " files"); - transferFiles(ftp); } + log(ACTION_STRS[action] + " files"); + transferFiles(ftp); } }