mirror of
https://github.com/GNS3/gns3-server
synced 2024-11-13 20:08:55 +00:00
Fix packet filters for Dynamips.
This commit is contained in:
parent
279b4d7b20
commit
85dcb985eb
@ -350,7 +350,9 @@ class Dynamips(BaseManager):
|
||||
sock.connect(sa)
|
||||
except OSError as e:
|
||||
raise DynamipsError("Could not create an UDP connection to {}:{}: {}".format(rhost, rport, e))
|
||||
nio = NIOUDP(node, lport, rhost, rport, nio_settings.get("filters", {}))
|
||||
nio = NIOUDP(node, lport, rhost, rport)
|
||||
nio.filters = nio_settings.get("filters", {})
|
||||
nio.suspend = nio_settings.get("suspend", False)
|
||||
elif nio_settings["type"] == "nio_generic_ethernet":
|
||||
ethernet_device = nio_settings["ethernet_device"]
|
||||
if sys.platform.startswith("win"):
|
||||
|
@ -79,12 +79,11 @@ class NIOUDP(NIO):
|
||||
|
||||
self._source_nio = nio_udp.NIOUDP(self._local_tunnel_rport,
|
||||
'127.0.0.1',
|
||||
self._local_tunnel_lport,
|
||||
{})
|
||||
self._local_tunnel_lport)
|
||||
self._destination_nio = nio_udp.NIOUDP(self._lport,
|
||||
self._rhost,
|
||||
self._rport,
|
||||
self._filters)
|
||||
self._rport)
|
||||
self._destination_nio.filters = self._filters
|
||||
yield from self._node.add_ubridge_udp_connection(
|
||||
self._bridge_name,
|
||||
self._source_nio,
|
||||
|
Loading…
Reference in New Issue
Block a user