Index: mttroot/mtt/bin/trans/m/abg2cbg.m ================================================================== --- mttroot/mtt/bin/trans/m/abg2cbg.m +++ mttroot/mtt/bin/trans/m/abg2cbg.m @@ -15,10 +15,13 @@ % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %% Version control history % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %% $Id$ % %% $Log$ +% %% Revision 1.21 1997/08/18 16:25:25 peterg +% %% Minor bug fixes +% %% % %% Revision 1.20 1997/08/18 12:45:24 peterg % %% Replaced: comp_bonds = bonds(bond_list,:) % %% by: for kk = 1:n_comp % %% comp_bonds(kk,:) = bonds(comp(kk),:); % %% end; @@ -170,13 +173,20 @@ if n_port_bonds~=n_ports mtt_info(sprintf('%s: %1.0f port bonds incompatible with %1.0f ports', ... full_name, n_port_bonds, n_ports), infofile); else % Copy the port bonds & status - j = abs(components(1:n_ports,1)) % relevant bond numbers - bonds(j,:) = port_bonds; - status(1:n_ports) = port_status; + port_bond_index = abs(components(1:n_ports,1)) % relevant bond numbers + for j = 1:n_port_bonds + jj = port_bond_index(j); + for k = 1:2 + if bonds(jj,k)==0 % only copy if not already set + bonds(jj,k) = port_bonds(j,k); + end; + end; + status(1:n_ports) = port_status; + end end else n_port_bonds=0; end; bonds,port_bonds