From: Vincent Bernat Date: Thu, 18 Sep 2014 09:27:21 +0000 (+0200) Subject: interfaces: only use physical interfaces to get a chassis ID X-Git-Tag: 0.7.11~18 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=790752d0b5e7941a2e368cee6e30df6695162752;p=thirdparty%2Flldpd.git interfaces: only use physical interfaces to get a chassis ID --- diff --git a/src/daemon/interfaces.c b/src/daemon/interfaces.c index d29eacc2..a52e99c2 100644 --- a/src/daemon/interfaces.c +++ b/src/daemon/interfaces.c @@ -288,8 +288,8 @@ interfaces_helper_vlan(struct lldpd *cfg, } #endif -/* Fill out chassis ID if not already done. This handler is special - because we will only handle interfaces that are already handled. */ +/* Fill out chassis ID if not already done. Only physical interfaces are + * considered. */ void interfaces_helper_chassis(struct lldpd *cfg, struct interfaces_device_list *interfaces) @@ -313,7 +313,7 @@ interfaces_helper_chassis(struct lldpd *cfg, return; /* We already have one */ TAILQ_FOREACH(iface, interfaces, next) { - if (iface->flags) continue; + if (!(iface->type & IFACE_PHYSICAL_T)) continue; if (cfg->g_config.c_cid_pattern && !pattern_match(iface->name, cfg->g_config.c_cid_pattern, 0)) continue;