From cc92ee388c44240042aa718e3b5dee955eb8e50a Mon Sep 17 00:00:00 2001 From: Ruben Kerkhof Date: Thu, 19 Mar 2020 14:00:20 +0100 Subject: [PATCH] bgpd: use the right format specifier Fixes: /Library/Developer/CommandLineTools/usr/bin/make all-am CC bgpd/bgp_attr.o bgpd/bgp_attr.c:2664:5: warning: format specifies type 'unsigned char' but the argument has type 'uint16_t' (aka 'unsigned short') [-Wformat] length, STREAM_READABLE(peer->curr)); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./lib/log.h:94:50: note: expanded from macro 'flog_err' zlog_err("[EC %" PRIu32 "] " format, ferr_id, ##__VA_ARGS__) ~~~~~~ ^~~~~~~~~~~ 1 warning generated. Signed-off-by: Ruben Kerkhof --- bgpd/bgp_attr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bgpd/bgp_attr.c b/bgpd/bgp_attr.c index 7c15fd3711..9afd3780e0 100644 --- a/bgpd/bgp_attr.c +++ b/bgpd/bgp_attr.c @@ -2659,7 +2659,7 @@ bgp_attr_parse_ret_t bgp_attr_prefix_sid(struct bgp_attr_parser_args *args, if (STREAM_READABLE(peer->curr) < length) { flog_err( EC_BGP_ATTR_LEN, - "Malformed Prefix SID attribute - insufficient data (need %" PRIu8 + "Malformed Prefix SID attribute - insufficient data (need %" PRIu16 " for attribute body, have %zu remaining in UPDATE)", length, STREAM_READABLE(peer->curr)); return bgp_attr_malformed(args,