open blocked connections

Hi,

I sometime run into the issue that I want to (re)open a connection that I do not have the socket handle for anymore. I'd also prefer not to call pnet(‘closeall’), as there are sometimes other connections that were already setup and that I need to keep.

Is there already a good solution for this?
One way to do this would be to allow pnet to return a list of all current connections (with socket handle and port), so I can close and reopen the socket handle.

The attached pnet.c has one possible implementation for this. If this is already ok, then it would be great if it could be added to PTB.
I’d also like to have something similar for IOPort and could add that functionality if this approach is ok.

thanks
Jonas Knoell