Search Issue Tracker
Won't Fix
Votes
0
Found in
2017.4
2019.3.3f1
2020.2
Issue ID
1223903
Regression
No
Calling the SendTo method on a UDP Socket causes an invalid pointer address exception
How to reproduce:
1. Open the attached project (1223903.zip)
2. Enter Play Mode and look at the Console window
Expected result: There are no errors in the Console window
Actual result: There is a "SocketException: The system detected an invalid pointer address in attempting to use a pointer argument in a call." error in the Console window
Reproducible with: 2017.4.37f1, 2018.4.19f1, 2019.3.4f1, 2020.1.0b1, 2020.2.0a2
Notes:
1. The issue reproduces when a "Socket" class instance is created where its "ProtocolType" is set to "Udp" and the "SocketType" is set to "Dgram" and then its "SendTo" method is called
2. When the same steps to create a "Socket" class instance and call the "SendTo" method are used in a C# console application it does not cause any errors
3. The "Actual result" section shows results for a Windows 10 PC, on a Mac, the thrown error is different: "SocketException: mono-io-layer-error (10022)"
4. Tested on a Windows 10 PC and Mac
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- UI Toolkit throws warning and fails to clear references when fields are not typed as UnityEngine.Object
- "Shader warning in 'Hidden/Light2D': implicit truncation of vector type" is thrown when building Universal 2D template
- AI Assistant breaks compilation of packages using System.Runtime.CompilerServices.Unsafe via auto-referencing
- Unity Hub checks the "Documentation" module by default on the 6.4 and 6.5 streams despite that it was unchecked with the previous installs
- Shortcut that toggles between Dopesheet and Curves Views in the Animation Window's Timeline is mislabed
Resolution Note:
After investigation, the sample console application provided by the use produces the same exception in Microsoft .Net 4.7.2 using IPV6. This is not an issue with Mono or Unity, most likely an IPV6 issue with DotNetty.