summaryrefslogtreecommitdiff
path: root/ospfd/ospf_packet.c
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@diac24.net>2016-11-13 12:19:14 +0900
committerDavid Lamparter <equinox@opensourcerouting.org>2017-03-08 00:15:39 +0100
commit4525281af19b5800ffce4bda83e0957d21ccad43 (patch)
tree8919c479f14116f3cae9fc5b051673e2f796371d /ospfd/ospf_packet.c
parent16077f2fc5f4d73648b4ebef877e1f021864358d (diff)
*: get rid of zlog(*, LOG_LEVEL, ...)
Result of running the following Coccinelle patch + fixups: <<EOF /* long-forms: zlog(NULL, <level>, ...) * => zlog_level(...) */ @@ expression list args; @@ - zlog(NULL, LOG_DEBUG, args) + zlog_debug(args) @@ expression list args; @@ - zlog(NULL, LOG_NOTICE, args) + zlog_notice(args) @@ expression list args; @@ - zlog(NULL, LOG_INFO, args) + zlog_info(args) @@ expression list args; @@ - zlog(NULL, LOG_WARNING, args) + zlog_warn(args) @@ expression list args; @@ - zlog(NULL, LOG_ERR, args) + zlog_err(args) /* long-forms: zlog(base->log, <level>, ...) * => zlog_level(...) */ @@ expression base; expression list args; @@ - zlog(base->log, LOG_DEBUG, args) + zlog_debug(args) @@ expression base; expression list args; @@ - zlog(base->log, LOG_NOTICE, args) + zlog_notice(args) @@ expression base; expression list args; @@ - zlog(base->log, LOG_INFO, args) + zlog_info(args) @@ expression base; expression list args; @@ - zlog(base->log, LOG_WARNING, args) + zlog_warn(args) @@ expression base; expression list args; @@ - zlog(base->log, LOG_ERR, args) + zlog_err(args) EOF Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Diffstat (limited to 'ospfd/ospf_packet.c')
-rw-r--r--ospfd/ospf_packet.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/ospfd/ospf_packet.c b/ospfd/ospf_packet.c
index bf78336ad5..a0cc367cd7 100644
--- a/ospfd/ospf_packet.c
+++ b/ospfd/ospf_packet.c
@@ -2971,9 +2971,8 @@ ospf_read (struct thread *thread)
ospf_ls_ack (iph, ospfh, ibuf, oi, length);
break;
default:
- zlog (NULL, LOG_WARNING,
- "interface %s: OSPF packet header type %d is illegal",
- IF_NAME (oi), ospfh->type);
+ zlog_warn("interface %s: OSPF packet header type %d is illegal",
+ IF_NAME(oi), ospfh->type);
break;
}
@@ -3453,8 +3452,8 @@ ospf_poll_timer (struct thread *thread)
nbr_nbma->t_poll = NULL;
if (IS_DEBUG_OSPF (nsm, NSM_TIMERS))
- zlog (NULL, LOG_DEBUG, "NSM[%s:%s]: Timer (Poll timer expire)",
- IF_NAME (nbr_nbma->oi), inet_ntoa (nbr_nbma->addr));
+ zlog_debug("NSM[%s:%s]: Timer (Poll timer expire)", IF_NAME(nbr_nbma->oi),
+ inet_ntoa(nbr_nbma->addr));
ospf_poll_send (nbr_nbma);
@@ -3477,8 +3476,8 @@ ospf_hello_reply_timer (struct thread *thread)
assert (nbr->oi);
if (IS_DEBUG_OSPF (nsm, NSM_TIMERS))
- zlog (NULL, LOG_DEBUG, "NSM[%s:%s]: Timer (hello-reply timer expire)",
- IF_NAME (nbr->oi), inet_ntoa (nbr->router_id));
+ zlog_debug("NSM[%s:%s]: Timer (hello-reply timer expire)",
+ IF_NAME(nbr->oi), inet_ntoa(nbr->router_id));
ospf_hello_send_sub (nbr->oi, nbr->address.u.prefix4.s_addr);