UPnP cleanup and fixes for #432

Code to fix the issues outlined in #432. The surgery was fairly invasive: I thought it best to leave the commits un-squashed so as to leave the transformations of the code as granular and obvious as possible. I'm happy to squash away if that's desired.

Notes:

* The generalization from 1 thing to n things made returning an error awkward. For example, if discovery fails on one device, that shouldn't affect the discovery of any other device. Mapping errors back to devices is awkward, requiring either parallel arrays or an additional field in the IGD struct, and much more complicated error-handling logic in the consumer. Since no error-handling logic beyond writing to log files was done by the upstream consumers, I elected to simply log errors to the debug log facilities instead of returning them to the consumer.
* I tested the changes with one of my local routers, Wireshark, and a miniupnpd instance in a VM. I didn't see a good way to automate testing of the discovery or port mapping mechanisms; the only readily testable portion of the API seems to be the search and port mapping request strings. These operations seem don't seem susceptible to regressions, but I can write tests if desired.
* Searching for multiple devices requires a bit of concurrency, which is frequently difficult to grok. I attempted to write the cleanest code possible and documented as well as I could, but I'd be particularly interested in feedback about how penetrable the solution is.
I agree that making the external IP address available as part of the IGD discovery process is going to be vital; I'll get to work on providing that. There's a couple other properties that I think may be useful that I'll probably add in for good measure (the connection status property and the NATEnabled property look like they might be particularly useful).

Thanks for the clarification on caching. On a related note, I was noticing that IGDs should refuse to add a port mapping for the same external port and protocol to a different internal client, where "internal client" means different IP address. This means that we could eventually exhaust our sequence of 10 random ports if the IP address of our local node changes several times for some reason (say it's dynamically assigned), unless we explicitly delete the mappings (I wasn't able to find any place in the code where such mapping deletion was done). I doubt it's a pressing concern; DHCP assignments usually don't change on a regular basis, but it could possibly be an issue long-term, so I figured I'd make a note of it.