From 0767b4f34e1ac7dfe003320e391d1cc2bb227003 Mon Sep 17 00:00:00 2001 From: Mark Stapp Date: Tue, 17 Mar 2020 08:57:42 -0400 Subject: [PATCH] bgpd,zebra: replace some more FUNCTION macros Replace some remaining __FUNCTION__ macros with __func__, now that we're trying to converge that way. Signed-off-by: Mark Stapp --- bgpd/bgp_packet.c | 12 ++++++------ zebra/redistribute.c | 3 +-- zebra/zebra_rnh.c | 2 +- 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/bgpd/bgp_packet.c b/bgpd/bgp_packet.c index a7b2bc3458..6c31ec1b98 100644 --- a/bgpd/bgp_packet.c +++ b/bgpd/bgp_packet.c @@ -2328,7 +2328,7 @@ int bgp_process_packet(struct thread *thread) flog_err( EC_BGP_PKT_OPEN, "%s: BGP OPEN receipt failed for peer: %s", - __FUNCTION__, peer->host); + __func__, peer->host); break; case BGP_MSG_UPDATE: atomic_fetch_add_explicit(&peer->update_in, 1, @@ -2339,7 +2339,7 @@ int bgp_process_packet(struct thread *thread) flog_err( EC_BGP_UPDATE_RCV, "%s: BGP UPDATE receipt failed for peer: %s", - __FUNCTION__, peer->host); + __func__, peer->host); break; case BGP_MSG_NOTIFY: atomic_fetch_add_explicit(&peer->notify_in, 1, @@ -2349,7 +2349,7 @@ int bgp_process_packet(struct thread *thread) flog_err( EC_BGP_NOTIFY_RCV, "%s: BGP NOTIFY receipt failed for peer: %s", - __FUNCTION__, peer->host); + __func__, peer->host); break; case BGP_MSG_KEEPALIVE: peer->readtime = monotime(NULL); @@ -2360,7 +2360,7 @@ int bgp_process_packet(struct thread *thread) flog_err( EC_BGP_KEEP_RCV, "%s: BGP KEEPALIVE receipt failed for peer: %s", - __FUNCTION__, peer->host); + __func__, peer->host); break; case BGP_MSG_ROUTE_REFRESH_NEW: case BGP_MSG_ROUTE_REFRESH_OLD: @@ -2371,7 +2371,7 @@ int bgp_process_packet(struct thread *thread) flog_err( EC_BGP_RFSH_RCV, "%s: BGP ROUTEREFRESH receipt failed for peer: %s", - __FUNCTION__, peer->host); + __func__, peer->host); break; case BGP_MSG_CAPABILITY: atomic_fetch_add_explicit(&peer->dynamic_cap_in, 1, @@ -2381,7 +2381,7 @@ int bgp_process_packet(struct thread *thread) flog_err( EC_BGP_CAP_RCV, "%s: BGP CAPABILITY receipt failed for peer: %s", - __FUNCTION__, peer->host); + __func__, peer->host); break; default: /* Suppress uninitialized variable warning */ diff --git a/zebra/redistribute.c b/zebra/redistribute.c index d1148061b9..80cc18a57d 100644 --- a/zebra/redistribute.c +++ b/zebra/redistribute.c @@ -173,8 +173,7 @@ void redistribute_update(const struct prefix *p, const struct prefix *src_p, afi = family2afi(p->family); if (!afi) { flog_warn(EC_ZEBRA_REDISTRIBUTE_UNKNOWN_AF, - "%s: Unknown AFI/SAFI prefix received\n", - __FUNCTION__); + "%s: Unknown AFI/SAFI prefix received\n", __func__); return; } if (!zebra_check_addr(p)) { diff --git a/zebra/zebra_rnh.c b/zebra/zebra_rnh.c index 6cfc68eb74..c758e25839 100644 --- a/zebra/zebra_rnh.c +++ b/zebra/zebra_rnh.c @@ -1030,7 +1030,7 @@ static int send_client(struct rnh *rnh, struct zserv *client, rnh_type_t type, default: flog_err(EC_ZEBRA_RNH_UNKNOWN_FAMILY, "%s: Unknown family (%d) notification attempted\n", - __FUNCTION__, rn->p.family); + __func__, rn->p.family); break; } if (re) { -- 2.39.5