mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-27 18:40:33 +01:00
platform: use nm_utils_ip4_address_clear_host_address()
We have this util function, presumably because it's good to have it. Use it. (cherry picked from commit3a545fd041) (cherry picked from commit09832c5639)
This commit is contained in:
parent
a585910b49
commit
e5c06f0c45
1 changed files with 2 additions and 2 deletions
|
|
@ -7971,8 +7971,8 @@ nm_platform_ip4_address_pretty_sort_cmp(const NMPlatformIP4Address *a1,
|
|||
* subnet (and thus also the primary/secondary role) is
|
||||
* preserved.
|
||||
*/
|
||||
n1 = a1->address & _nm_utils_ip4_prefix_to_netmask(a1->plen);
|
||||
n2 = a2->address & _nm_utils_ip4_prefix_to_netmask(a2->plen);
|
||||
n1 = nm_utils_ip4_address_clear_host_address(a1->address, a1->plen);
|
||||
n2 = nm_utils_ip4_address_clear_host_address(a2->address, a2->plen);
|
||||
NM_CMP_DIRECT_MEMCMP(&n1, &n2, sizeof(guint32));
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue