From 75585e213de850395b6bcd0aff0841cd9cced92c Mon Sep 17 00:00:00 2001 From: imarom Date: Tue, 22 Nov 2016 17:16:36 +0200 Subject: RX features - few tweaks Signed-off-by: imarom --- .../trex_control_plane/stl/trex_stl_lib/utils/common.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'scripts/automation/trex_control_plane/stl/trex_stl_lib/utils/common.py') diff --git a/scripts/automation/trex_control_plane/stl/trex_stl_lib/utils/common.py b/scripts/automation/trex_control_plane/stl/trex_stl_lib/utils/common.py index 02e13fd7..cbbacb27 100644 --- a/scripts/automation/trex_control_plane/stl/trex_stl_lib/utils/common.py +++ b/scripts/automation/trex_control_plane/stl/trex_stl_lib/utils/common.py @@ -98,3 +98,13 @@ def is_valid_ipv4 (addr): def is_valid_mac (mac): return bool(re.match("[0-9a-f]{2}([-:])[0-9a-f]{2}(\\1[0-9a-f]{2}){4}$", mac.lower())) +def list_remove_dup (l): + tmp = list() + + for x in l: + if not x in tmp: + tmp.append(x) + + return tmp + + -- cgit 1.2.3-korg