slirp: Allow disabling IPv4 or IPv6

Add ipv4 and ipv6 boolean options, so the user can setup IPv4-only and
IPv6-only network environments.

Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
This commit is contained in:
Samuel Thibault 2016-03-20 12:29:54 +01:00
parent de1d099a44
commit 0b11c03662
9 changed files with 74 additions and 10 deletions

View file

@ -24,6 +24,11 @@ void ip6_cleanup(Slirp *slirp)
void ip6_input(struct mbuf *m)
{
struct ip6 *ip6;
Slirp *slirp = m->slirp;
if (!slirp->in6_enabled) {
goto bad;
}
DEBUG_CALL("ip6_input");
DEBUG_ARG("m = %lx", (long)m);