From f8d4611d15b18bf505de9ca82d74f5102fc57024 Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Tue, 12 Aug 2014 17:20:34 -0700 Subject: (1) Tweak LAN locator beacon frequencies, (2) Windows virtual networks now show up as *real* networks and prompt the user to set their location and firewall status (public, private, home/work, etc.). The hack used to achieve #2 should not be examined by children or those suffering from epilepsy or heart conditions. --- osnet/WindowsRoutingTable.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'osnet/WindowsRoutingTable.cpp') diff --git a/osnet/WindowsRoutingTable.cpp b/osnet/WindowsRoutingTable.cpp index aa215fb0..eef03ae6 100644 --- a/osnet/WindowsRoutingTable.cpp +++ b/osnet/WindowsRoutingTable.cpp @@ -151,7 +151,9 @@ RoutingTable::Entry WindowsRoutingTable::set(const InetAddress &destination,cons _copyInetAddressToSockaddrInet(gateway,nr.NextHop); nr.Metric = metric; nr.Protocol = MIB_IPPROTO_NETMGMT; - CreateIpForwardEntry2(&nr); + DWORD result = CreateIpForwardEntry2(&nr); + if (result != NO_ERROR) + return RoutingTable::Entry(); } std::vector rtab(get(true,true)); -- cgit v1.2.3