check is_v6() for ipv6
Merge pull request #25 from cybozu/fix_issue_23

check is_v6() for ipv6