mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-06-13 18:00:38 +00:00
Fix the code to handle multiple activate, found bug with UT cases
This commit is contained in:
@ -1180,7 +1180,10 @@ sub parse_args {
|
||||
}
|
||||
|
||||
if (scalar @flash_arguments > 1) {
|
||||
if ($filename_passed and $option_flag !~ /^-d$/) {
|
||||
if (($option_flag =~ /^-a$|^--delete$/) or ($filename_passed and $option_flag !~ /^-d$/)) {
|
||||
# Handles:
|
||||
# - Multiple options not supported to activate/delete at the same time
|
||||
# - Filename passed in and option is not -d for directory
|
||||
return ([1, "More than one firmware specified is not supported."]);
|
||||
} elsif ($option_flag =~ /^-d$/) {
|
||||
return ([1, "More than one directory specified is not supported."]);
|
||||
|
Reference in New Issue
Block a user