fix issue where reload stops sending stats

* The real issue was `cfg->socket` not being initialized and possibly grabbing dirty memory, thus thinking it has a socket / file descriptor when it really just has a random int.
* Decided to reset the socket whenever a write issue occurs - tested and this does recover nicely.
* Also added a `free_function` to clean up old sockets / file descriptors when a VCL is discarded.

Feel free to cherry pick if you don't want to change all of this.  :+1: