mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-04 14:30:18 +01:00
trivial: rename 'link' to avoid shadowing a global variable/function
nm-system.c: In function "nm_system_bond_enslave": nm-system.c:1689:21: error: declaration of "link" shadows a global declaration [-Werror=shadow]
This commit is contained in:
parent
0e0b5da7e3
commit
db7ba1c161
1 changed files with 6 additions and 6 deletions
|
|
@ -1686,15 +1686,15 @@ nm_system_bond_enslave (gint master_ifindex,
|
|||
g_assert (!nm_system_iface_is_up (slave_ifindex));
|
||||
|
||||
if (nm_system_iface_get_flags (slave_ifindex) & IFF_SLAVE) {
|
||||
struct rtnl_link *link;
|
||||
struct rtnl_link *l;
|
||||
int existing_master = -1;
|
||||
|
||||
/* Get the ifindex of the existing master device */
|
||||
link = nm_netlink_index_to_rtnl_link (slave_ifindex);
|
||||
g_warn_if_fail (link != NULL);
|
||||
if (link) {
|
||||
existing_master = rtnl_link_get_master (link);
|
||||
rtnl_link_put (link);
|
||||
l = nm_netlink_index_to_rtnl_link (slave_ifindex);
|
||||
g_warn_if_fail (l != NULL);
|
||||
if (l) {
|
||||
existing_master = rtnl_link_get_master (l);
|
||||
rtnl_link_put (l);
|
||||
}
|
||||
|
||||
if (existing_master > 0) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue