Fix ArrayIndexOutOfRange in DelayableCommand.

This commit is contained in:
asofold 2012-10-05 00:43:38 +02:00
parent 5baaedce74
commit 59063c7497

View File

@ -115,7 +115,7 @@ public abstract class DelayableCommand extends NCPCommand {
// Parse the delay and alter the args accordingly.
long delay = parseDelay(args, delayIndex, delayPreset);
String[] alteredArgs;
if (delay == -1){
if (args.length <= delayIndex){
// No delay found, if demanded return.
if (mustHaveDelay) return false;
alteredArgs = args;