Verified Commit 5e740cae authored by Andrey Vertiprahov's avatar Andrey Vertiprahov
Browse files

Generic.get_lldp_neighbors. Fix trace wnen local_id not in names.

parent 76f2d1d8
......@@ -55,7 +55,11 @@ class Script(BaseScript):
elif port_subtype == LLDP_PORT_SUBTYPE_MAC:
# Iface MAC address
raise NotImplementedError()
elif port_subtype == LLDP_PORT_SUBTYPE_LOCAL and port_id.isdigit():
elif (
and port_id.isdigit()
and int(port_id) in names
# Iface local (ifindex)
iface_name = names[int(port_id)]
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment