]> git.ipfire.org Git - thirdparty/lldpd.git/commitdiff
lldpd: cleanup phase is done in `update_local_ports()`
authorVincent Bernat <bernat@luffy.cx>
Sun, 30 Dec 2012 10:05:55 +0000 (11:05 +0100)
committerVincent Bernat <bernat@luffy.cx>
Sun, 30 Dec 2012 10:05:55 +0000 (11:05 +0100)
Cleaning up unused ports and chassis is really part of updating local
ports process.

src/daemon/lldpd.c

index 00ff4f7eba557dfbb8e32946c4e43aecb149fd26..53bec842cd39769bda2a9f619cb94a71d405250e 100644 (file)
@@ -911,6 +911,7 @@ lldpd_update_localports(struct lldpd *cfg)
            hardware->h_flags = 0;
 
        interfaces_update(cfg);
+       lldpd_cleanup(cfg);
 }
 
 void
@@ -927,8 +928,6 @@ lldpd_loop(struct lldpd *cfg)
        LOCAL_CHASSIS(cfg)->c_cap_enabled = 0;
        log_debug("loop", "update information for local ports");
        lldpd_update_localports(cfg);
-       log_debug("loop", "cleanup pass");
-       lldpd_cleanup(cfg);
        log_debug("loop", "update information for local chassis");
        lldpd_update_localchassis(cfg);
        log_debug("loop", "send appropriate PDU on all interfaces");