socket-dynamic: Use IPv6-only mode for IPv6 sockets