]> git.ipfire.org Git - thirdparty/lldpd.git/commit
Use ifAlias from newer Linux kernels if available.
authorVincent Bernat <bernat@luffy.cx>
Wed, 10 Jun 2009 13:22:29 +0000 (15:22 +0200)
committerVincent Bernat <bernat@luffy.cx>
Wed, 10 Jun 2009 13:22:29 +0000 (15:22 +0200)
commit36bd79e367cdf45c4bff70aa7241bceb4e7c5e34
tree1b355c92c81eef0cf90f0e9c18451a0efbcb906c
parent44002d6615d6c8bd3390333b51c89dc99c235207
Use ifAlias from newer Linux kernels if available.

From 2.6.28, Linux allows to attach a description to an interface. We
grab this description from /sys/class/net/$IFACE/ifalias if it exists
and is not empty and use it as port description. In this case,
interface name is used as port ID.

 PortID:    veth0 (ifName)
 PortDescr: Test interface

This closes ticket #10.
CHANGELOG
src/interfaces.c
src/priv.c