Closed GoogleCodeExporter closed 9 years ago
No; you do not need to set AutoExpandMTU to true; fragmentation is always
enabled. In fact, try to set it to false and you may not get those errors...
MTU expansion is a new feature and can be a bit flakey.
Original comment by lidg...@gmail.com
on 18 May 2011 at 11:22
Tried with disabled AutoExpandMTU. (disabled by default).
No any special options for Lidgren library.
So strange.
Original comment by IvanEfi...@gmail.com
on 18 May 2011 at 11:41
AutoExpandMTU = True solves the problem.
But still don't know this is good way or no.
Original comment by IvanEfi...@gmail.com
on 19 May 2011 at 10:09
I've also discovered this issue. It revealed when I tried to send message with
length of 1404 bytes and my MTU = 1408. The lib choose to not fragment this
message and then when service header is added it becomes larger than MTU which
generates this exception. (see NetConnection.cs, line 305).
I've solved this issue by changing the code line 49 in NetPeer.Send.cs to
int len = msg.GetEncodedSize();
It works for me.
Is it acceptable and valid fix?
Original comment by oga...@servicerepairsolutions.com
on 8 Jun 2011 at 7:02
Nice catch! I added a fix in rev 239 (and 240 made it a const) - calling
GetEncodedSize would actually be more proper, but I opted for the more
performant way of just adding the header size.
Original comment by lidg...@gmail.com
on 8 Jun 2011 at 7:24
Original issue reported on code.google.com by
IvanEfi...@gmail.com
on 18 May 2011 at 9:58