#958 Remove and Replace character tag of items from CLI fix

This commit is contained in:
honfika@gmail.com
2015-07-09 08:41:45 +02:00
parent 4f35fd8e28
commit 45a19deed3
2 changed files with 3 additions and 3 deletions

View File

@@ -2008,8 +2008,8 @@ public class CommandLineArgumentParser {
System.err.println("Tag number should be integer");
System.exit(1);
}
if (swf.tags.size() >= tagNo) {
System.err.println("Tag number does not exist. Last tag number is: " + (swf.tags.size() - 1));
if (tagNo < 0 || tagNo >= swf.tags.size()) {
System.err.println("Tag number does not exist. Tag number should be between 0 and " + (swf.tags.size() - 1));
System.exit(1);
}