Interface enumeration order is not stable across refreshes, so detect topology changes by comparing the address sets rather than array order.
| 440 | // Interface enumeration order is not stable across refreshes, so detect |
| 441 | // topology changes by comparing the address sets rather than array order. |
| 442 | static bool HaveSameAddressSet(const dmArray<dmSocket::Address>& lhs, const dmArray<dmSocket::Address>& rhs) |
| 443 | { |
| 444 | if (lhs.Size() != rhs.Size()) |
| 445 | return false; |
| 446 | |
| 447 | for (uint32_t i = 0; i < lhs.Size(); ++i) |
| 448 | { |
| 449 | if (!ContainsAddress(rhs, lhs[i])) |
| 450 | return false; |
| 451 | } |
| 452 | |
| 453 | return true; |
| 454 | } |
| 455 | |
| 456 | static bool RefreshBrowserInterfaceAddresses(Browser* browser) |
| 457 | { |
no test coverage detected