From 62cf6600520180630237635cf0d857fceef8c389 Mon Sep 17 00:00:00 2001 From: "janbronicki@gmail.com" Date: Wed, 12 May 2021 13:12:29 +0200 Subject: [PATCH] [#5] Sorted import --- src/Renode/Network/NetworkServer/IServerModule.cs | 2 +- .../NetworkServer/Modules/IcmpServerModule.cs | 14 +++++++------- src/Renode/Network/NetworkServer/NetworkServer.cs | 13 +++++-------- 3 files changed, 13 insertions(+), 16 deletions(-) diff --git a/src/Renode/Network/NetworkServer/IServerModule.cs b/src/Renode/Network/NetworkServer/IServerModule.cs index 24388f457..7855be4c4 100644 --- a/src/Renode/Network/NetworkServer/IServerModule.cs +++ b/src/Renode/Network/NetworkServer/IServerModule.cs @@ -6,8 +6,8 @@ // using System; -using System.Net; using System.Collections.Generic; +using System.Net; using PacketDotNet; namespace Antmicro.Renode.Network diff --git a/src/Renode/Network/NetworkServer/Modules/IcmpServerModule.cs b/src/Renode/Network/NetworkServer/Modules/IcmpServerModule.cs index b948a9a75..735e3ca93 100644 --- a/src/Renode/Network/NetworkServer/Modules/IcmpServerModule.cs +++ b/src/Renode/Network/NetworkServer/Modules/IcmpServerModule.cs @@ -6,19 +6,17 @@ // using System; +using System.Collections.Generic; using System.IO; using System.Net; -using System.Collections.Generic; using System.Net.NetworkInformation; using System.Threading.Tasks; - -using PacketDotNet; - using Antmicro.Renode.Core; using Antmicro.Renode.Core.Structure; -using Antmicro.Renode.Logging; using Antmicro.Renode.Exceptions; +using Antmicro.Renode.Logging; using Antmicro.Renode.Utilities; +using PacketDotNet; using PacketDotNet.Utils; @@ -162,8 +160,10 @@ private EthernetFrame CreateEthernetFramePacket(IPv4Packet ipv4Packet, ICMPv4Pac var ethernetResponse = new EthernetPacket((PhysicalAddress)MAC, icmpDestinationAddress, - EthernetPacketType.None); - ethernetResponse.PayloadPacket = ipv4Packet; + EthernetPacketType.None) + { + PayloadPacket = ipv4Packet + }; icmpv4PacketResponse.UpdateCalculatedValues(); this.Log(LogLevel.Noisy, "Sending response: {0}", diff --git a/src/Renode/Network/NetworkServer/NetworkServer.cs b/src/Renode/Network/NetworkServer/NetworkServer.cs index 2915418a2..dd7ed8ee5 100644 --- a/src/Renode/Network/NetworkServer/NetworkServer.cs +++ b/src/Renode/Network/NetworkServer/NetworkServer.cs @@ -6,20 +6,17 @@ // using System; +using System.Collections.Generic; using System.IO; +using System.Linq; using System.Net; using System.Net.NetworkInformation; -using System.Collections.Generic; - -using PacketDotNet; - using Antmicro.Renode.Core; using Antmicro.Renode.Core.Structure; -using Antmicro.Renode.Peripherals.Network; -using Antmicro.Renode.Logging; using Antmicro.Renode.Exceptions; - -using System.Linq; +using Antmicro.Renode.Logging; +using Antmicro.Renode.Peripherals.Network; +using PacketDotNet; namespace Antmicro.Renode.Network {