CodePlexProject Hosting for Open Source Software
for copying a payload data to a byte array, I m using the following code
byte qas = new byte[udp.Payload.Length];
for (int i = 0; i < udp.Payload.Length; i++)
qas[i] = udp.Payload[i];
Is there any other efficient way for doing this.
this looks fine , why do you want to change it ??
Is there a memory copy operation which would be quicker ? Or is the fo rloop for such small data just as quick ?
Just thinking of capture/resend at high rates (ie. 24Mb/s++)
I think this code is not so efficient for parsing payload of every packet during live packet capture. This code is open for critics
piece of code for efficient
I suggest using ToMemoryStream() on the Datagram and then reading from that MemoryStream efficiently.
Are you sure you want to delete this post? You will not be able to recover it later.
Are you sure you want to delete this thread? You will not be able to recover it later.