mirror of
				https://github.com/xcat2/xcat-core.git
				synced 2025-10-30 19:02:27 +00:00 
			
		
		
		
	return values are zero for updatenode -f with incompatiable flags -k -S -P
This commit is contained in:
		| @@ -142,6 +142,12 @@ if (($SECURITY) && (($SWMAINTENANCE) || defined($RERUNPS) || ($FILESYNC) || ($SN | ||||
|     exit 1; | ||||
| } | ||||
|  | ||||
| if ($SNFILESYNC && ($SWMAINTENANCE || defined($RERUNPS) || $SECURITY || $FILESYNC)){ | ||||
|     my $msg = "If you specify the -f flag you must not specify either the -S or -k or -P or -F flags"; | ||||
|     xCAT::MsgUtils->message("E", $msg); | ||||
|     exit 1; | ||||
| } | ||||
|  | ||||
| # determine who is running the command on the client and who we will run as  | ||||
| # on the node | ||||
| my $current_userid = getpwuid($>); | ||||
|   | ||||
| @@ -387,6 +387,7 @@ sub preprocess_updatenode | ||||
|     { | ||||
|         my $rsp = {}; | ||||
|         $rsp->{data}->[0] = "You can not specify both the -f and -F flags."; | ||||
|         $rsp->{errorcode}->[0] =1; | ||||
|         $callback->($rsp); | ||||
|         return; | ||||
|     } | ||||
| @@ -395,8 +396,8 @@ sub preprocess_updatenode | ||||
|     { | ||||
|         my $rsp = {}; | ||||
|         $rsp->{data}->[0] = | ||||
|           "If you specify the -f flag you must not specify either the -S or -k or -P or -F | ||||
|  flags"; | ||||
|           "If you specify the -f flag you must not specify either the -S or -k or -P or -F flags"; | ||||
|         $rsp->{errorcode}->[0] =1; | ||||
|         $callback->($rsp); | ||||
|         return; | ||||
|     }  | ||||
| @@ -407,7 +408,8 @@ sub preprocess_updatenode | ||||
|     { | ||||
|         my $rsp = {}; | ||||
|         $rsp->{data}->[0] = | ||||
|           "If you use the -k flag, you cannot specify the -S,-P,-f  or -F flags."; | ||||
|           "If you use the -k flag, you cannot specify the -S,-P,-f or -F flags."; | ||||
|         $rsp->{errorcode}->[0] =1; | ||||
|         $callback->($rsp); | ||||
|         return; | ||||
|     } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user