Fix #23 on issue tracker.

There is a race condition if IPv4 and IPv6 connections come at the same time.