mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-23 21:00:28 +01:00
platform: fix detection of link-type for netlink event
Often a netlink event doesn't contain enough information to determine
the link type. Then we consult sysctl or ethtool. However, if we already
have the same object cached, we want to reused the (once detected) link-type.
There was a bug in lookup of the cached object.
(cherry picked from commit 9c0cfbbae6)
This commit is contained in:
parent
afb2447789
commit
ab667dd885
1 changed files with 1 additions and 1 deletions
|
|
@ -878,7 +878,7 @@ _lookup_link_cached (NMPlatform *platform, int ifindex, gboolean *completed_from
|
|||
if (!*completed_from_cache) {
|
||||
obj = ifindex > 0 ? nmp_cache_lookup_link (NM_LINUX_PLATFORM_GET_PRIVATE (platform)->cache, ifindex) : NULL;
|
||||
|
||||
if (obj && !obj->_link.netlink.is_in_netlink)
|
||||
if (obj && obj->_link.netlink.is_in_netlink)
|
||||
*link_cached = obj;
|
||||
else
|
||||
*link_cached = NULL;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue