mirror of
https://github.com/SoftEtherVPN/SoftEtherVPN.git
synced 2024-11-22 17:39:53 +03:00
Merge pull request #1659 from domosekai/route6
This commit is contained in:
commit
e4f9abba1c
@ -9414,8 +9414,16 @@ RETRY:
|
||||
{
|
||||
e = ZeroMallocFast(sizeof(ROUTE_ENTRY));
|
||||
Win32IpForwardRow2ToRouteEntry(e, &p->Table[i]);
|
||||
|
||||
if (e->Active)
|
||||
{
|
||||
Add(o, e);
|
||||
}
|
||||
else
|
||||
{
|
||||
FreeRouteEntry(e);
|
||||
}
|
||||
}
|
||||
FreeMibTable(p);
|
||||
|
||||
// Sort by metric
|
||||
@ -9573,6 +9581,7 @@ void Win32IpForwardRow2ToRouteEntry(ROUTE_ENTRY *entry, void *ip_forward_row)
|
||||
{
|
||||
entry->IfMetric = p->Metric;
|
||||
entry->Metric = r->Metric + p->Metric;
|
||||
entry->Active = p->Connected;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -293,6 +293,7 @@ struct ROUTE_ENTRY
|
||||
UINT IfMetric;
|
||||
UINT InterfaceID;
|
||||
UINT64 InnerScore;
|
||||
bool Active;
|
||||
};
|
||||
|
||||
// Routing table
|
||||
|
Loading…
Reference in New Issue
Block a user