[tools] testbot/TestAgent: Simplify the implementation for commands with no argument.
1 Apr
2022
1 Apr
'22
3:09 p.m.
Signed-off-by: Francois Gouget <fgouget(a)codeweavers.com> --- testbot/scripts/TestAgent | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/testbot/scripts/TestAgent b/testbot/scripts/TestAgent index ea18b85b7..a3d6e2625 100755 --- a/testbot/scripts/TestAgent +++ b/testbot/scripts/TestAgent @@ -210,15 +210,7 @@ while (@ARGV) @Rm = @ARGV; last; } - elsif ($arg eq "getcwd") - { - $Cmd = $arg; - } - elsif ($arg eq "getversion") - { - set_cmd($arg); - } - elsif ($arg eq "ping" or $arg eq "settime") + elsif ($arg =~ /^(?:getcwd|getversion|ping|settime)$/) { set_cmd($arg); } -- 2.30.2
1353
Age (days ago)
1353
Last active (days ago)
0 comments
1 participants
participants (1)
-
Francois Gouget