From 91b2e023b8ddf53b2c4484330be244fd286bc939 Mon Sep 17 00:00:00 2001 From: Christian Helmuth Date: Thu, 7 Jun 2018 15:05:46 +0200 Subject: [PATCH] vfs/lxip: make gateway config attribute optional This enables the application in router/gateway-less network configurations, e.g., test environments. --- repos/dde_linux/src/lib/vfs/lxip/vfs.cc | 6 +----- repos/libports/run/netty.inc | 2 +- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/repos/dde_linux/src/lib/vfs/lxip/vfs.cc b/repos/dde_linux/src/lib/vfs/lxip/vfs.cc index 5f3e2e7fb..54f1e196a 100644 --- a/repos/dde_linux/src/lib/vfs/lxip/vfs.cc +++ b/repos/dde_linux/src/lib/vfs/lxip/vfs.cc @@ -1616,19 +1616,15 @@ class Vfs::Lxip_file_system : public Vfs::File_system, Addr gateway = config.attribute_value("gateway", Addr()); Addr nameserver = config.attribute_value("nameserver", Addr()); - /* either none or all 4 interface attributes must exist */ if (ip_addr == "") { warning("Missing \"ip_addr\" attribute. Ignoring network interface config."); throw Genode::Xml_node::Nonexistent_attribute(); } else if (netmask == "") { warning("Missing \"netmask\" attribute. Ignoring network interface config."); throw Genode::Xml_node::Nonexistent_attribute(); - } else if (gateway == "") { - warning("Missing \"gateway\" attribute. Ignoring network interface config."); - throw Genode::Xml_node::Nonexistent_attribute(); } - log("static network interface: ip_addr=",ip_addr," netmask=",netmask," gateway=",gateway); + log("static network interface: ip_addr=",ip_addr," netmask=",netmask); lxip_configure_static(ip_addr.string(), netmask.string(), gateway.string(), nameserver.string()); diff --git a/repos/libports/run/netty.inc b/repos/libports/run/netty.inc index 4dce90225..805671b80 100644 --- a/repos/libports/run/netty.inc +++ b/repos/libports/run/netty.inc @@ -64,7 +64,7 @@ append_if [use_dynamic_rom] config { - +