Mark's networking code

As cleaned up by @ediosyncratic using git filter-branch (among other dangerous tools).
Includes several fixups from later in the branch, but I may have missed some.
Compiled locally and passes all unit and acceptance tests.  Let's see how it fares more widely ...

I suspect reviewing the gross diff is easiest, as there are (even after squashing out a few) quite a lot of changes of mind along the way.  Also: 106 commits.
A function of this name exists in Win32 API:


    13:39:58 verify_interfaces.c:59:12: error: conflicting types for 'GetInterfaceInfo'
    13:39:58 /usr/lib/gcc/i686-w64-mingw32/4.6/../../../../i686-w64-mingw32/include/iphlpapi.h:50:16: note: previous declaration of 'GetInterfaceInfo' was here