Fixed bug when parsing IPv6 addresses spotted by @cr0hn