]> git.ozlabs.org Git - ppp.git/commitdiff
Implement get_first_ethernet() for Linux systems properly
authorPali Rohár <pali@kernel.org>
Wed, 30 Dec 2020 10:00:11 +0000 (11:00 +0100)
committerPali Rohár <pali@kernel.org>
Wed, 30 Dec 2020 10:00:11 +0000 (11:00 +0100)
Use if_nameindex() for enumerating network interfaces and choose the first
one with ARPHRD_ETHER ifr_hwaddr.sa_family.

Signed-off-by: Pali Rohár <pali@kernel.org>

No differences found