Note that there are some explanatory texts on larger screens.

plurals
  1. POSome Windows 7 installs not releasing UDP Socket on UdpClient.Close()?
    primarykey
    data
    text
    <p>A coworker and I have identical code on identical hardware running almost-identical installs of Windows 7. We are both using C# from within Unity3d, and the latest SVN checkout of the <a href="https://code.google.com/p/unity3d-tuio/" rel="nofollow">unity3d-tuio</a> package. TUIO is an Open Sound Control-based UDP protocol for sending data about touch-screen interaction. On my machine, the application works fine the first time I run it (although there is a strange ~5 second delay on startup), but any subsequent time the app is started, it throws the following exception:</p> <pre><code>SocketException: Only one usage of each socket address (protocol/network address/port) is normally permitted. System.Net.Sockets.Socket.Bind (System.Net.EndPoint local_end) System.Net.Sockets.UdpClient.InitSocket (System.Net.EndPoint localEP) System.Net.Sockets.UdpClient..ctor (System.Net.IPEndPoint localEP) Tuio.TuioTracking.Start () (at Assets/Plugins/MindstormTuio/Scripts/TuioReceiver/TuioTracking.cs:70) UnityEngine.Debug:LogException(Exception) </code></pre> <p>For my coworker, there is no strange delay on startup, and the app can be restarted as many times as desired with no ill effects. </p> <p>If I run <code>netstat -a -n -o</code> on my machine, I see that a UDP connection -- <code>UDP 0.0.0.0:3333 *:* 6088</code> -- is open even after the application and the Unity editor exit. I have determined by running <code>tasklist /F "PID EQ 6088"</code> while running the app for the first time that the PID (in this case 6088) is Unity.exe (the Unity editor). It appears that the first time the app is executed, Unity.exe grabs port 3333 and won't release it. Even after exiting the Unity editor, the <code>UDP 0.0.0.0:3333 *:* 6088</code> entry appears in netstat. </p> <p>Seems to be a configuration problem specific to my dev machine, since my coworker's machine does not exhibit it. </p> <p>Any ideas what configuration issues could cause this problem?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload