System.Net.SendWol.SendPacketAsync C# (CSharp) Method

SendPacketAsync() private static method

private static SendPacketAsync ( IPEndPoint target, byte packet ) : Task
target IPEndPoint
packet byte
return Task
        private static Task SendPacketAsync(IPEndPoint target, byte[] packet)
        {
            var cl = new UdpClient();
            return cl.SendAsync(packet, packet.Length, target).ContinueWith((Task t) => cl.Close());
        }