Module: tools Branch: master Commit: de94f940a061c8d5525f1ef52759b1cddeedf2ac URL: http://source.winehq.org/git/tools.git/?a=commit;h=de94f940a061c8d5525f1ef52...
Author: Francois Gouget fgouget@codeweavers.com Date: Tue Dec 11 12:08:55 2012 +0100
testbot/TestAgent: Fix the TestAgent script parameter checks.
---
testbot/scripts/TestAgent | 14 +++++++------- 1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/testbot/scripts/TestAgent b/testbot/scripts/TestAgent index b861ba2..6d241b5 100755 --- a/testbot/scripts/TestAgent +++ b/testbot/scripts/TestAgent @@ -167,25 +167,25 @@ if (!defined $Usage) error("you must specify a command\n"); $Usage = 2; } - elsif ($Cmd eq "run" and !@Run) + elsif ($Cmd ne "sendfile" and $SendFlags) { - error("you must specify the command to run\n"); + error("the --sendfile-xxx options can only be used with the sendfile command\n"); $Usage = 2; } - elsif ($Cmd eq "rm" and !@Rm) + elsif ($Cmd eq "run" and !@Run) { - error("you must specify the server files to delete\n"); + error("you must specify the command to run\n"); $Usage = 2; } - if ($Cmd ne "run" and ($RunFlags or defined $RunIn or defined $RunOut or + elsif ($Cmd ne "run" and ($RunFlags or defined $RunIn or defined $RunOut or defined $RunErr)) { error("the --run-xxx options can only be used with the run command\n"); $Usage = 2; } - elsif ($Cmd ne "sendfile" and $SendFlags) + elsif ($Cmd eq "rm" and !@Rm) { - error("the --sendfile-xxx options can only be used with the sendfile command\n"); + error("you must specify the server files to delete\n"); $Usage = 2; } $AgentPort = $Port if (defined $Port);