1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-30 14:55:37 +03:00

network: route: tighten variable scope

Follow-up for 5e82a61375.
This commit is contained in:
Yu Watanabe 2021-12-08 05:37:42 +09:00
parent f333ed27fa
commit f14a6e7f48

View File

@ -1646,7 +1646,6 @@ int manager_rtnl_process_route(sd_netlink *rtnl, sd_netlink_message *message, Ma
Link *link = NULL;
uint32_t ifindex;
uint16_t type;
unsigned char table;
size_t rta_len;
int r;
@ -1785,6 +1784,8 @@ int manager_rtnl_process_route(sd_netlink *rtnl, sd_netlink_message *message, Ma
r = sd_netlink_message_read_u32(message, RTA_TABLE, &tmp->table);
if (r == -ENODATA) {
unsigned char table;
r = sd_rtnl_message_route_get_table(message, &table);
if (r >= 0)
tmp->table = table;