Dup the forwarded ports array while destroying to avoid issues with changes in virtualbox gem and deleting in place
This commit is contained in:
parent
abf6a50b5a
commit
1e01514c4f
|
@ -68,7 +68,8 @@ module Vagrant
|
|||
|
||||
def clear
|
||||
logger.info "Deleting any previously set forwarded ports..."
|
||||
@runner.vm.forwarded_ports.collect { |p| p.destroy }
|
||||
fp = @runner.vm.forwarded_ports.dup
|
||||
fp.collect { |p| p.destroy }
|
||||
@runner.reload!
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue