Fetching v0 and v2 rendezvous descriptors in parallel sometimes fails
The logic to download v0 and v2 rendezvous descriptors in parallel does not work correctly. If the v0 request returns first and unsuccessfully, the hidden service connection is closed with the statement "[notice] Closing stream for '[...].onion': hidden service is unavailable (try again later)." A subsequent successful result of a v2 request cannot be processed correctly; while the descriptor is stored for later use, it cannot be used for the requesting connection any more.
This is a minor problem, since hidden services that only publish v2 descriptors are still rare (unless people perform tests with them).
Patch follows.
[Automatically added by flyspray2trac: Operating System: All]