#include "routetable.h"
+#ifdef DEBUG
+#include <iostream>
+#endif
RouteTable::RouteTable(Dev& default_iface): default_iface(default_iface)
{
}
-void RouteTable::add(const IPAddr& net, const IPAddr& gw, unsigned metric, Dev& iface)
+void RouteTable::add(const IPAddr& net, const IPAddr& gw, unsigned mtu,
+ unsigned metric, Dev& iface)
{
- table[net] = Route(gw, metric, iface);
+ table[net] = Route(gw, metric, mtu, iface);
+#ifdef DEBUG
+ //std::cout << "Se agregó tabla para " << net << ": gw = " << gw
+ // << ", metric = " << metric << "\n";
+#endif
}
void RouteTable::del(const IPAddr& net)