New Ticket     Tickets     Wiki     Browse Source     Timeline     Roadmap     Ticket Reports     Search

Changeset 79518


Ignore:
Timestamp:
06/16/11 07:33:19 (4 years ago)
Author:
jmr@…
Message:

restrict recursing both ways when uninstalling with both --follow-dependencies and --follow-dependents

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/base/src/registry2.0/portuninstall.tcl

    r79517 r79518  
    114114    # uninstall dependents if requested 
    115115    if {[info exists options(ports_uninstall_follow-dependents)] && $options(ports_uninstall_follow-dependents) eq "yes"} { 
     116        # don't uninstall dependents' dependencies 
     117        if {[info exists options(ports_uninstall_follow-dependencies)]} { 
     118            set orig_follow_dependencies $options(ports_uninstall_follow-dependencies) 
     119            unset options(ports_uninstall_follow-dependencies) 
     120            set optionslist [array get options] 
     121        } 
    116122        foreach depport [$port dependents] { 
    117123            # make sure it's still installed, since a previous dep uninstall may have removed it 
     
    121127                } 
    122128            } 
     129        } 
     130        if {[info exists orig_follow_dependencies]} { 
     131            set options(ports_uninstall_follow-dependencies) $orig_follow_dependencies 
     132            set optionslist [array get options] 
    123133        } 
    124134    } else { 
     
    212222    # uninstall dependencies if requested 
    213223    if {[info exists options(ports_uninstall_follow-dependencies)] && [string is true -strict $options(ports_uninstall_follow-dependencies)]} { 
     224        # don't uninstall dependencies' dependents 
     225        if {[info exists options(ports_uninstall_follow-dependents)]} { 
     226            unset options(ports_uninstall_follow-dependents) 
     227            set optionslist [array get options] 
     228        } 
    214229        while 1 { 
    215230            set remaining_list {} 
Note: See TracChangeset for help on using the changeset viewer.