From: stevenvanrossem Date: Wed, 8 Feb 2017 00:04:36 +0000 (+0100) Subject: fix bug - vlan was added to monitoring links on single switch paths X-Git-Tag: v3.1~45^2~9 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=263eee56ae3a0d4aa2b48cd1afb42de3b1ddee65;p=osm%2Fvim-emu.git fix bug - vlan was added to monitoring links on single switch paths --- diff --git a/src/emuvim/dcemulator/net.py b/src/emuvim/dcemulator/net.py index 30b7ce2..af6fbad 100755 --- a/src/emuvim/dcemulator/net.py +++ b/src/emuvim/dcemulator/net.py @@ -456,6 +456,7 @@ class DCNetwork(Containernet): kwargs['switch_inport_name'] = src_sw_inport_name kwargs['switch_outport_name'] = dst_sw_outport_name kwargs['skip_vlan_tag'] = True + kwargs['pathindex'] = i monitor_placement = kwargs.get('monitor_placement').strip() # put monitor flow at the dst switch @@ -615,10 +616,9 @@ class DCNetwork(Containernet): switch_inport_nr = src_sw_inport_nr # choose free vlan - ## if path contains more than 1 switch cmd = kwargs.get('cmd') vlan = None - if cmd == 'add-flow' and len(path) > 1: + if cmd == 'add-flow': if kwargs.get('tag'): # use pre-defined tag vlan = kwargs.get('tag')