From: Sam Tannous Date: Tue, 8 Jul 2014 19:15:39 +0000 (-0400) Subject: lldpd: fix log_info X-Git-Tag: 0.7.10~31 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=254e5134d9338f0d20f47b30d9ad0934fc7fe93b;p=thirdparty%2Flldpd.git lldpd: fix log_info Currently none of the log_info msgs are getting printed into syslog. vlog already does the right checks. Remove the checks in log_info which is making all default log_info prints no-ops Also change severity of "interface reset timer" msg Signed-off-by: Roopa Prabhu Signed-off-by: Sam Tannous --- diff --git a/src/daemon/lldpd.c b/src/daemon/lldpd.c index cc113e35..5c197488 100644 --- a/src/daemon/lldpd.c +++ b/src/daemon/lldpd.c @@ -315,7 +315,7 @@ lldpd_reset_timer(struct lldpd *cfg) cksum = frame_checksum(output, output_len, 0); free(output); if (cksum != hardware->h_lport_cksum) { - log_info("localchassis", + log_debug("localchassis", "change detected for port %s, resetting its timer", hardware->h_ifname); hardware->h_lport_cksum = cksum; diff --git a/src/log.c b/src/log.c index 5a1db221..4a1647e7 100644 --- a/src/log.c +++ b/src/log.c @@ -195,11 +195,9 @@ log_info(const char *token, const char *emsg, ...) { va_list ap; - if (debug > 1 || logh) { - va_start(ap, emsg); - vlog(LOG_INFO, token, emsg, ap); - va_end(ap); - } + va_start(ap, emsg); + vlog(LOG_INFO, token, emsg, ap); + va_end(ap); } static int