Changeset 730
- Timestamp:
- 05/21/15 14:55:10 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/cgi-bin/IPDB.pm
r729 r730 2127 2127 2128 2128 if ($args{scope} eq 'keepall') { 2129 # Create a new parent with the same info as the passed "primary". 2130 $newparent->execute($newblock, $args{newtype}, $prime); 2131 # and now retrieve the new parent ID 2132 ($prime) = $dbh->selectrow_array("SELECT currval('allocations_id_seq')"); 2133 # Reparent the free blocks in the new block 2134 $fbreparentsth->execute($prime, $binfo->{master_id}, $binfo->{city}, $newcontainerclass, $binfo->{vrf}, 2135 $binfo->{parent_id}, $newblock); 2136 # keep existing allocations (including the original primary), just push them down a level 2137 while (my ($pcidr,$peer_id,$ptype,$m_id) = $peersth->fetchrow_array) { 2138 $reparentsth->execute($prime, $binfo->{master_id}, $peer_id); 2139 # Fix up master_id on free blocks if we're merging a master block 2140 $mfbsth->execute($binfo->{master_id}, $m_id) if $ptype eq 'mm'; 2141 } 2142 2129 2143 } elsif ($args{scope} =~ /^clear/) { 2130 2144 } elsif ($args{scope} eq 'mergepeer') { # should this just be an else?
Note:
See TracChangeset
for help on using the changeset viewer.