lnobad / lidgren-network-gen3

Automatically exported from code.google.com/p/lidgren-network-gen3
0 stars 0 forks source link

GetMTU creates Garbage #123

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. CallSendMessage
2. ProfileApp

What is the expected output? What do you see instead?

I expect minimal garbage - instead I see GetMTU creating 
Generic.List<T>.Enumerator for each call.

What version of the product are you using? On what operating system?
May 26th release/Windows7/VS2011

Please provide any additional information below.

You fixed a similar issue here 
https://groups.google.com/forum/?fromgroups#!topic/lidgren-network-gen3/lvvvpDOC
Sxs

You can either make the parameter a List<T> ratehr than IList or simply iterate 
with a for look rather then foreach see 
http://blogs.msdn.com/b/etayrien/archive/2007/03/17/foreach-garbage-and-the-clr-
profiler.aspx

Original issue reported on code.google.com by z...@thezbuffer.com on 8 Jun 2012 at 6:53

GoogleCodeExporter commented 9 years ago
Fixed in 299, thanks!

Original comment by lidg...@gmail.com on 2 Jul 2012 at 7:10