There are about 10 socket derived classes in gnucleus for a variety of specific purposes. I try to keep the Close() method accross them the same.
You're referencing some old code there though, I'm pretty active with updates usually so I suggest going to gnucleus.net, reading the instructions for getting the latest source and checking it out.
The current code first locks the thread the socket is being closed in and once it is locked does this:
AsyncSelect(0);
ShutDown(1);
I took the clean receive buffer stuff out of there because it was pointless.
There is a huge bug with misdirectedn messages in CAsyncSocket derived classes, but it is fixed by putting AsyncSelect(0); in the deconstructor. It took me sooo long to find that simple fix. |