Changeset 365
- Timestamp:
- Sep 17, 2018, 11:24:54 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/ddt/ddt
r364 r365 1129 1129 control_exist_sector($computer_db, $sector) or exit; 1130 1130 1131 $mac = get_mac_from_hostname($computer_db, $sector, $hostname, $mac);1132 control_syntax_mac_address($mac) or exit;1133 1134 1131 LOOP_ON_COMPUTER: 1135 1132 for my $computer (@{$computer_db->{$sector}}) { 1136 1133 my ($mac_address, $attribute) = %{$computer}; 1137 1134 1138 next LOOP_ON_COMPUTER if $mac_address ne $mac; 1135 next LOOP_ON_COMPUTER if $attribute->{'hostname'} ne $hostname; 1136 1137 die "Warning: host $hostname already of type $type\n" if $attribute->{'address_type'} eq $type; 1139 1138 1140 1139 $attribute->{'address_type'} = $type; … … 1144 1143 exit; 1145 1144 } 1146 print"Error: change host $hostname type [FAILED]\n";1145 die "Error: change host $hostname type [FAILED]\n"; 1147 1146 } 1148 1147
Note: See TracChangeset
for help on using the changeset viewer.