network: check the received interface name is actually new
authorYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 12 Jul 2021 12:23:41 +0000 (21:23 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Tue, 13 Jul 2021 10:20:31 +0000 (19:20 +0900)
commit176b8be10ffce2f8c1fc931a37904a528057016f
treea8c9c0ea34553b71023e878f037a2b420004230b
parent85e424c0c852fcb92d108494a6efa9dd0ce943b2
network: check the received interface name is actually new

For some reasons I do not know, on interface renaming, kernel once send
netlink message with old interface name, and then send with new name.
If eth0 is renamed, and then new interface appears as eth0, then the
message with the old name 'eth0' makes the interface enters failed
state.

To ignore such invalid(?) rename event messages, let's confirm the
received interface name.

Fixes #20203.
src/network/networkd-link.c