Skip to content

Commit

Permalink
backport/2.8/58231 ce_netstream_aging: update to fix a bug. (#58231) (
Browse files Browse the repository at this point in the history
…#58563)

* ce_netstream_aging: update to fix a bug. (#58231)

* update to fix a bug

* update to for shippable.

(cherry picked from commit 715de33)

* add a changelog fragment.

* Update 58563-update-ce_netstream_aging-to-fix-a-bug.yml
  • Loading branch information
YuandongXu authored and abadger committed Jul 9, 2019
1 parent ae17f38 commit 9724b23
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
bugfixes:
- ce_netstream_aging - line318, Redundant regular.
line326,line33, there may be out of array rang,some time.(https://github.com/ansible/ansible/pull/58231)
5 changes: 2 additions & 3 deletions lib/ansible/modules/network/cloudengine/ce_netstream_aging.py
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,6 @@ def get_end_timer_out_para(self):
tcp_tmp["vxlan"] = "absent"
flags = list()
exp = " | ignore-case include netstream timeout"
exp = "| ignore-case include evpn-overlay enable"
flags.append(exp)
config = get_config(self.module, flags)
if config:
Expand All @@ -324,14 +323,14 @@ def get_end_timer_out_para(self):
for config_mem in config_list:
config_mem = config_mem.lstrip()
config_mem_list = config_mem.split(' ')
if config_mem_list[2] == "ip":
if len(config_mem_list) > 4 and config_mem_list[2] == "ip":
if config_mem_list[3] == "active":
active_tmp["ip"] = config_mem_list[4]
if config_mem_list[3] == "inactive":
inactive_tmp["ip"] = config_mem_list[4]
if config_mem_list[3] == "tcp-session":
tcp_tmp["ip"] = "present"
if config_mem_list[2] == "vxlan":
if len(config_mem_list) > 5 and config_mem_list[2] == "vxlan":
if config_mem_list[4] == "active":
active_tmp["vxlan"] = config_mem_list[5]
if config_mem_list[4] == "inactive":
Expand Down

0 comments on commit 9724b23

Please sign in to comment.