Skip to content

Commit

Permalink
Add FTP.setControlEncoding(Charset)
Browse files Browse the repository at this point in the history
Fail-fast in command-line example
  • Loading branch information
garydgregory committed Feb 19, 2025
1 parent 135272f commit 11785fd
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
import java.io.OutputStream;
import java.net.InetAddress;
import java.net.UnknownHostException;
import java.nio.charset.Charset;
import java.time.Duration;
import java.util.Arrays;

Expand Down Expand Up @@ -124,7 +125,7 @@ public static void main(final String[] args) throws UnknownHostException {
String proxyPassword = null;
String user = null;
String password = null;
String encoding = null;
Charset encoding = null;
String serverTimeZoneId = null;
String displayTimeZoneId = null;
String serverType = null;
Expand All @@ -151,7 +152,7 @@ public static void main(final String[] args) throws UnknownHostException {
} else if (args[base].equals("-e")) {
useEpsvWithIPv4 = true;
} else if (args[base].equals("-E")) {
encoding = args[++base];
encoding = Charset.forName(args[++base]);
} else if (args[base].equals("-f")) {
feat = true;
minParams = 3;
Expand Down

0 comments on commit 11785fd

Please sign in to comment.