Skip to content

Commit

Permalink
Re-add empty flag checking
Browse files Browse the repository at this point in the history
  • Loading branch information
masonsbro committed Jun 12, 2013
1 parent 9d91542 commit 1e73d89
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/main/java/com/sk89q/mclauncher/util/BasicArgsParser.java
Expand Up @@ -48,6 +48,9 @@ public ArgsContext parse(String[] args) {
for (int i = 0; i < args.length; i++) {
String arg = args[i];
if (arg.startsWith("-")) {
if (arg.length() == 1) {
throw new IllegalArgumentException("Flag with no name");
}
String flag = arg.substring(1);
if (valueArgs.contains(flag)) {
wantingFlag = flag;
Expand Down

0 comments on commit 1e73d89

Please sign in to comment.