Fix several problems with wire network.  Fixes #1029.